customer_mdedit.html 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535
  1. {Template header}
  2. <body>
  3. <div class="warp">
  4. <div class="packing">
  5. <div class="control">
  6. <a href="javascript:void(0);" class="exptj">添 加</a>
  7. <a href="javascript:void(0);" class="expxg">修 改</a>
  8. <a href="javascript:void(0);" class="expsc">删 除</a>
  9. {if $user == 'admin' || $user == 'PIFA'}
  10. <a href="javascript:void(0);" class="window2" data-h="/specialstock/order" data-t="库存选择">库存选择</a>
  11. {/if}
  12. </div>
  13. <table class="datatitle data" border="0" style="border-collapse:collapse;">
  14. <tr>
  15. <td>商品名称</td>
  16. <td>数量</td>
  17. <td class="none">单价</td>
  18. <td class="none">总价</td>
  19. <td class="none">币种</td>
  20. <td class="none"></td>
  21. <td class="none"></td>
  22. <td class="none"></td>
  23. <td class="none"></td>
  24. <td class="none"></td>
  25. <td class="none"></td>
  26. <td>操作</td>
  27. </tr>
  28. </table>
  29. <table class="datatext data" border="0" style="border-collapse:collapse;">
  30. {loop $fpdata as $val}
  31. <tr data-list="{$val['0']}">
  32. <td>{$val['1']}</td>
  33. <td>{$val['2']}</td>
  34. <td class="none">{$val['3']}</td>
  35. <td class="none">{$val['4']}</td>
  36. <td class="none">CNY</td>
  37. <td class="none">{$val['5']}</td>
  38. <td class="none">{$val['6']}</td>
  39. <td class="none">{$val['7']}</td>
  40. <td class="none">{$val['8']}</td>
  41. <td class="none val9">{if isset($val['9'])}{$val['9']}{else}0{/if}</td>
  42. <td class="czzd">{if $val['9'] != 'DNOTO'}<font class="jzzd">禁止占单</font>{else}<font class="yxzd">允许占单<font>{/if}</td>
  43. </tr>
  44. {/loop}
  45. </table>
  46. </div>
  47. <ul class="setting">
  48. <div class="need">
  49. <li>
  50. <em>订单号:</em>
  51. <input name="orderinfo" value="" type="text" readonly style="background-color: #ebebe4;">
  52. </li>
  53. <li>
  54. <em>线下单类型:</em>
  55. <select name="sourcetype" class="select class">
  56. <option value="1">网红单</option>
  57. <option value="2">批发单</option>
  58. <option value="3">线下单</option>
  59. <option value="4">售后单</option>
  60. <option value="5">其它</option>
  61. </select>
  62. </li>
  63. <li>
  64. <em>发货仓库:</em>
  65. <select name="warehouse" id="warehouse" class="select class">
  66. {loop warehouse(100) as $val}
  67. <option value="{$val['id']}" data-e="{$val['express']}">{$val['title']}</option>
  68. {/loop}</select>
  69. </li>
  70. <li>
  71. <em>结算币种:</em>
  72. <select name="currency" id="currency" class="select class">
  73. {loop typeclass(30) as $val}
  74. <option value="{$val['id']}" {if $val['id'] == '219'}selected="selected"{/if}>{$val['title']}</option>
  75. {/loop}
  76. </select>
  77. </li>
  78. <li>
  79. <em>资金状态:</em>
  80. <select name="capital" class="select class">
  81. <option value="3" {if $fullorder['capital'] == 3}selected="selected"{/if}>全部支付</option>
  82. <option value="1" {if $fullorder['capital'] == 1}selected="selected"{/if}>暂未支付</option>
  83. <option value="2" {if $fullorder['capital'] == 2}selected="selected"{/if}>部分支付</option>
  84. </select>
  85. </li>
  86. <li>
  87. <em>所属店铺:</em>
  88. <select name="shop" class="select class">
  89. {loop usershop() as $val}
  90. <option value="{$val['id']}" {if $customer['shop'] == $val['id']}selected="selected"{/if}>{$val['shopname']}</option>
  91. {/loop}</select>
  92. </li>
  93. <li>
  94. <em>订单金额:</em>
  95. <input name="shouldmoney" class="must currencymoney" value="" type="text" {if $fullorder['shouldmoney'] > 200}style="color:#F00"{/if}> <font class="currency">CNY</font>
  96. </li>
  97. <li class="none">
  98. <em>运费:</em>
  99. <input name="freight" class="must currencymoney" value="0" type="text"> <font class="currency">CNY</font>
  100. </li>
  101. <li class="none">
  102. <em>物流金额:</em>
  103. <input name="expressmoney" class="must currencymoney" value="0" type="text"> <font class="currency">CNY</font>
  104. </li>
  105. <li>
  106. <em>丢件险:</em>
  107. <input name="insurance" class="must currencymoney" value="0" type="text"> <font class="currency">CNY</font>
  108. </li>
  109. <li class="length remark">
  110. <em>产品标题:</em>
  111. <textarea class="must" name="product"></textarea>
  112. </li>
  113. <li>
  114. <em>交易号:</em>
  115. <input name="paypal" value="" type="text">
  116. </li>
  117. <li>
  118. <em>卖家保障:</em>
  119. <input name="guarantee" value="" type="text">
  120. </li>
  121. <li class="lengththree">
  122. <em>支付方式:</em>
  123. <select name="pay" class="select class">
  124. {loop typeclass(4,3,100) as $val}
  125. <option value="{$val['id']}">{$val['title']}</option>
  126. {/loop}</select>
  127. </li>
  128. <li class="lengththree">
  129. <em>Quantity:</em>
  130. <input class="must" name="quantity" value="" type="text">
  131. </li>
  132. <li class="lengththree">
  133. <em>付款时间:</em>
  134. <input id="buytime" class="must" value="" name="buytime" type="text" >
  135. <i class="time fa fa-calendar fa-lg"></i>
  136. </li>
  137. <li class="length remark">
  138. <em>订单备注:</em>
  139. <textarea name="orderremarks"></textarea>
  140. </li>
  141. <li class="length remark">
  142. <em>仓库品名:</em>
  143. <textarea class="must" name="shipremarks"></textarea>
  144. </li>
  145. <li>
  146. <em>Bill Name:</em>
  147. <input name="bname" class="must" value="{$customer['name']}" type="text">
  148. </li>
  149. <li>
  150. <em>Ship Name:</em>
  151. <input name="sname" class="must" value="{$customer['name']}" type="text">
  152. </li>
  153. <li class="length remark">
  154. <em>Bill Address:</em>
  155. <input class="must" name="baddress" value="{$customer['address']},{$customer['city']},{$customer['province']},{$customer['zipcode']},{$bm['al']},{$customer['phone']}" type="text">
  156. </li>
  157. <li class="length remark">
  158. <em>Ship Address:</em>
  159. <input class="must" name="saddress" value="{$customer['address']},{$customer['city']},{$customer['province']},{$customer['zipcode']},{$bm['al']},{$customer['phone']}" type="text">
  160. </li>
  161. <li>
  162. <em>邮箱:</em>
  163. <input class="must" name="email" value="{$customer['email']}" type="text">
  164. </li>
  165. <li>
  166. <em>国家:</em>
  167. <select name="country" class="select class">
  168. {loop $country as $val}
  169. <option value="{$val['id']}" {if $customer['country'] == $val['id']}selected="selected"{/if}>{$val['name']}</option>
  170. {/loop}
  171. </select>
  172. </li>
  173. <li>
  174. <em>联系方式:</em>
  175. <input name="phone" class="must" value="{$customer['phone']}" type="text">
  176. </li>
  177. <li>
  178. <em>省州:</em>
  179. <input class="must" value="{$customer['province']}" name="province" type="text">
  180. </li>
  181. <li>
  182. <em>公司名:</em>
  183. <input class="must" name="client" value="{$customer['name']}" type="text">
  184. </li>
  185. <li>
  186. <em>城市:</em>
  187. <input class="must" value="{$customer['city']}" name="city" type="text">
  188. </li>
  189. <li>
  190. <em>收货人姓名:</em>
  191. <input name="name" class="must" value="{$customer['name']}" type="text">
  192. </li>
  193. <li>
  194. <em>邮编:</em>
  195. <input value="{$customer['zipcode']}" name="zipcode" type="text">
  196. </li>
  197. {if $is == 5}
  198. <!--
  199. <li class="length">
  200. <em>街道:</em>
  201. <input value="{$customer['street']}" name="street" type="text">
  202. </li>
  203. -->
  204. {/if}
  205. <li class="length">
  206. <em>地址2:</em>
  207. <input value="{$customer['address2']}" name="address2" type="text">
  208. </li>
  209. <li class="length">
  210. <em>地址1:</em>
  211. <input value="{$customer['address']}" name="address" type="text">
  212. </li>
  213. <li class="lengththree">
  214. <em>申报品名:</em>
  215. <select name="sbpm" class="select class">
  216. {loop customsdeclaration(50) as $val}
  217. <option value="{$val['ename']}">{$val['ename']}</option>
  218. {/loop}
  219. </select>
  220. </li>
  221. <li class="lengththree">
  222. <em>中文品名:</em>
  223. <select name="zwpm" class="select class">
  224. {loop customsdeclaration(50) as $val}
  225. <option value="{$val['zname']}">{$val['zname']}</option>
  226. {/loop}
  227. </select>
  228. </li>
  229. <li class="lengththree">
  230. <em>海关编码:</em>
  231. <select name="hgbm" class="select class">
  232. {loop customsdeclaration(50) as $val}
  233. <option value="{$val['bname']}">{$val['bname']}</option>
  234. {/loop}
  235. </select>
  236. </li>
  237. <li class="lengththree">
  238. <em>条数:</em>
  239. <input name="ts" class="must" value="" type="text">
  240. </li>
  241. <li class="lengththree">
  242. <em>单条申报价:</em>
  243. <input name="dtsbjz" class="must" value="" type="text">
  244. </li>
  245. <li class="lengththree">
  246. <em>总申报价:</em>
  247. <input name="zsbjz" class="must" value="0.00" type="text">
  248. </li>
  249. <li class="lengththree">
  250. <em>总重量:</em>
  251. <input name="zzl" class="must" value="0.4" type="text">
  252. </li>
  253. <li class="lengththree">
  254. <em>总件数:</em>
  255. <input name="zjs" class="must" value="1" type="text" readonly style="background-color: #ebebe4;">
  256. </li>
  257. <li class="lengththree">
  258. <em>快递方式:</em>
  259. <select name="express" class="select class">
  260. {loop express(100) as $val}
  261. <option value="{$val['id']}" data-type="{$val['type']}" {if $fullorder['express'] == $val['id']}selected="selected"{/if}>{$val['servicename']}</option>
  262. {/loop}
  263. </select>
  264. </li>
  265. <li class="lengththree">
  266. <em>打印类型:</em>
  267. <select name="printtype" class="printtype select class">
  268. <option value="1">运单</option>
  269. <option value="2">发货单</option>
  270. <option value="3">不打印单据</option>
  271. </select>
  272. </li>
  273. <li class="lengththree">
  274. <div class="none">
  275. <em>发送留言:</em>
  276. <select name="msg" class="printtype select class">
  277. <option value="1">1</option>
  278. <option value="2">2</option>
  279. </select>
  280. </div>
  281. </li>
  282. <li class="lengththree">
  283. <em>IOSS:</em>
  284. <select name="ioss" class="select class">
  285. <option value="">未选择</option>
  286. {loop ioss(100) as $val}
  287. <option value="{$val['ioss']}">{$val['title']}</option>
  288. {/loop}
  289. </select>
  290. </li>
  291. <li class="lengththree">
  292. <em>购买保险:</em>
  293. <input name="bx" class="must" value="{if $fullorder['bx']}{$fullorder['bx']}{else}0.00{/if}" type="text"> USD
  294. </li>
  295. <li class="lengththree">
  296. <em>是否签名:</em>
  297. <select name="qm" class="printtype select class">
  298. <option value="0">不需要</option>
  299. <option value="1">需要</option>
  300. </select>
  301. </li>
  302. <li class="lengththree">
  303. <em>服务类型:</em>
  304. <select name="js" class="printtype select class">
  305. <option value="0" {if $fullorder['js'] == 0}selected="selected"{/if}>Ground Advantage</option>
  306. <option value="1" {if $fullorder['js'] == 1}selected="selected"{/if}>PRIORITY</option>
  307. <option value="2" {if $fullorder['js'] == 2}selected="selected"{/if}>EXPRESS</option>
  308. </select>
  309. </li>
  310. <li class="lengththree none">
  311. <em>延迟发货:</em>
  312. <select name="yc" class="printtype select class">
  313. <option value="0" {if $fullorder['yc'] == 0}selected="selected"{/if}>0</option>
  314. <option value="1" {if $fullorder['yc'] == 1}selected="selected"{/if}>1</option>
  315. <option value="2" {if $fullorder['yc'] == 2}selected="selected"{/if}>2</option>
  316. <option value="3" {if $fullorder['yc'] == 3}selected="selected"{/if}>3</option>
  317. <option value="4" {if $fullorder['yc'] == 4}selected="selected"{/if}>4</option>
  318. <option value="5" {if $fullorder['yc'] == 5}selected="selected"{/if}>5</option>
  319. <option value="6" {if $fullorder['yc'] == 6}selected="selected"{/if}>6</option>
  320. <option value="7" {if $fullorder['yc'] == 7}selected="selected"{/if}>7</option>
  321. </select>
  322. </li>
  323. <!--
  324. <li class="productdescription none">
  325. <em>产品描述:</em>
  326. <select name="productdescription" class="select class">
  327. </select>
  328. </li>
  329. <li class="customs none">
  330. <em>海关价值:</em>
  331. <input value="" name="customs" type="text"> <font class="currency">CNY</font>
  332. </li>
  333. -->
  334. </div>
  335. <div style="clear:both;"></div>
  336. </ul>
  337. <div class="need"><input type="hidden" name="id" value="" />
  338. <input type="hidden" name="purchase" value="" />
  339. <input type="hidden" name="cost" value="" />
  340. <input type="hidden" name="et" value="{isset($et) ?$et : '0'}" />
  341. <input type="hidden" name="jgyc" value="1" />
  342. <input type="hidden" name="customerid" value="{$customer['id']}" />
  343. <input type="hidden" name="shop" value="{$customer['shop']}" />
  344. <input type="hidden" name="mdedit" value="" />
  345. </div>
  346. <div class="button"><font class="yzaddress" style="margin-right:160px;">USPS验证地址</font> <font class="fullorderdata-ts">保 存</font> <font class="fh">关 闭</font></div>
  347. </div>
  348. <div class="none fullorderdata"></div>
  349. <div class="zm none"></div>
  350. <script type="text/javascript">
  351. var addedit="/customer/mdedit/";
  352. var fh="/fullorder";
  353. $(document).ready(function() {
  354. if($("select[name='express']").find("option:selected").val() == '24')//联邦的话替换签名选项
  355. {
  356. $("select[name='qm']").html('<option value="0" {if $fullorder["qm"] == 0}selected="selected"{/if}>默认</option><option value="1" {if $fullorder["qm"] == 1}selected="selected"{/if}>成人签名</option>');
  357. }
  358. else
  359. {
  360. $("select[name='qm']").html('<option value="0" {if $fullorder["qm"] == 0}selected="selected"{/if}>不需要</option><option value="1" {if $fullorder["qm"] == 1}selected="selected"{/if}>需要</option>');
  361. }
  362. $("#buytime").calendar();$("#buytimeCalendar").css('position','absolute')
  363. var index = $("#currency").find("option:selected").text();
  364. $(".currency").text(index);
  365. $(".datatext tr").each(function() {
  366. $(this).find("td:eq(9)").text(index);
  367. //currencymoney需要更改的价格
  368. });
  369. custom();
  370. var index = $("select[name='printtype']").find("option:selected").index();
  371. if(index == 0)
  372. {
  373. var e = $("select[name=express]").find("option:selected").val();
  374. var c = $("select[name=country]").find("option:selected").val();
  375. $.ajax({
  376. url: "/fullorder/customs/",
  377. data: "e="+e+"&c="+c,
  378. type: "POST",
  379. dataType: "json",
  380. success: function(a) {
  381. if (a && a.success) {
  382. $("input[name=customs]").val(a.money);
  383. for(i=0;i<a.msg.length;i++)
  384. {
  385. $("select[name=productdescription]").append("<option value='"+a.msg[i]['id']+"'>"+a.msg[i]['title']+"</option>");
  386. }
  387. $(".productdescription").show();
  388. $(".customs").show();
  389. } else {
  390. $(".productdescription").hide();
  391. $(".customs").hide();
  392. }
  393. }
  394. });
  395. }else
  396. {
  397. $(".productdescription").hide();
  398. $(".customs").hide();
  399. }
  400. });
  401. function custom() {
  402. var num = $('.packing .datatitle tr').children().length;
  403. $('.data tr td').css("width","5%");
  404. $(".data tr").each(function() {
  405. $(this).find('td:eq(0)').css("width","30%");
  406. });}
  407. //监听input开始
  408. $("input[name=dtsbjz]").bind("input propertychange",function(event){
  409. var ts = $("input[name=ts]").val()*1;
  410. var dtsbjz = $("input[name=dtsbjz]").val()*1;
  411. var num = ts*dtsbjz;
  412. console.log($("input[name=zsbjz]").val(num.toFixed(2)))
  413. });
  414. $("input[name=ts]").bind("input propertychange",function(event){
  415. var ts = $("input[name=ts]").val()*1;
  416. var dtsbjz = $("input[name=dtsbjz]").val()*1;
  417. var num = ts*dtsbjz;
  418. console.log($("input[name=zsbjz]").val(num.toFixed(2)))
  419. });
  420. //监听input结束
  421. $(".window2").click(function() {
  422. var h = $(this).data("h");var t = $(this).data("t");
  423. window.parent.window2(t,h);
  424. });
  425. $('.fullorderdata-ts').click(function()
  426. {
  427. var tjje = $("input[name='shouldmoney']").val();
  428. var tjwl = $("select[name='express']").children("option:selected").val();
  429. var tjqm = $("select[name='qm']").children("option:selected").val();
  430. var fwlx = $("select[name='js']").children("option:selected").val();
  431. if(tjje > 750 && (tjwl == 24 || tjwl == 31 || tjwl == 2) && tjqm != 1)
  432. {
  433. layx.confirm('提示','此金额和物流可以选择购买“签名”服务',null,{
  434. buttons:[
  435. {
  436. label:'操作签名',
  437. callback:function(id, button, event){
  438. layx.destroy(id);
  439. }
  440. },
  441. {
  442. label:'保存信息',
  443. callback:function(id, button, event){
  444. $('.fullorderdata').click();
  445. layx.destroy(id);
  446. }
  447. }
  448. ]
  449. });
  450. }
  451. else if(fwlx == 2)
  452. {
  453. layx.confirm('提示','确定要发“收费加急”吗?(请提前收取加急运费)',null,{
  454. buttons:[
  455. {
  456. label:'确定',
  457. callback:function(id, button, event){
  458. $('.fullorderdata').click();
  459. layx.destroy(id);
  460. }
  461. },
  462. {
  463. label:'取消',
  464. callback:function(id, button, event){
  465. layx.destroy(id);
  466. }
  467. }
  468. ]
  469. });
  470. }
  471. else
  472. {
  473. $('.fullorderdata').click();
  474. }
  475. });
  476. </script>
  477. <script type="text/javascript" src="{$theme}js/time.js"></script>
  478. <script src="{$theme}js/fullorder-addedit.js?v=202309060001"></script>
  479. {Template footer}