mirror of
https://gitee.com/ShopeX/OMS
synced 2026-03-31 05:25:32 +08:00
36 lines
1.1 KiB
HTML
36 lines
1.1 KiB
HTML
<!--
|
||
Copyright © ShopeX (http://www.shopex.cn). All rights reserved.
|
||
See LICENSE file for license details.
|
||
-->
|
||
|
||
<{if $use_import_template}>
|
||
<form method="post" action="index.php?app=<{$env.get.app}>&ctl=<{$env.get.ctl}>&act=exportTemplate" class="tableform" target="download" enctype="multipart/form-data">
|
||
模板下载:
|
||
<button class="btn btn-primary" type="submit"><span><span>下载</span></span></button>
|
||
</form>
|
||
<{/if}>
|
||
|
||
<form action='<{$thisUrl}>&action=to_import' method='post' target="uploadframe" enctype="multipart/form-data" id="import_form" class="tableform">
|
||
<h4><{t}>上传.CSV文件<{/t}></h4>
|
||
<div class="division" >
|
||
<input type='file' name='import_file' id='ImportCSV'/>
|
||
</div>
|
||
<div class="table-action">
|
||
<{button label=$___desktop="导入"|t:'desktop' id="ImportBtn" type="submit"}>
|
||
</div>
|
||
</form>
|
||
<script>
|
||
(function(){
|
||
var state;
|
||
$('ImportBtn').addEvent('click',function(e){
|
||
if(state||!$('ImportCSV').value.length)return false;
|
||
state=true;
|
||
this.style.cursor='not-allowed';
|
||
});
|
||
$('ImportCSV').addEvent('change',function(e){
|
||
state=false;
|
||
$('ImportBtn').style.cursor='pointer';
|
||
});
|
||
})();
|
||
</script>
|