时间:2021-07-01 10:21:17 帮助过:8人阅读
include("conn.php");
if(isset($_POST['text']))
{
$text=$_POST['text'];
$t = date('Ymd', strtotime("-$text day"));
}
else
{
$t = date('Ymd', strtotime('-5 day'));
}
//warehouse_mix.txt
$hk_warehouse = array();
foreach(glob('download/hk_warehouse_mix*.txt') as $hk_warehouse_fn) {
if(substr($hk_warehouse_fn, 16, 8)>$t)
{
$hk_warehouse[] = $hk_warehouse_fn;
}
}
$jp_warehouse=array();
foreach(glob('download/jp_warehouse_mix*.txt') as $jp_warehouse_fa) {
if(substr($jp_warehouse_fa, 16, 8)>$t)
{
$jp_warehouse[] = $jp_warehouse_fa;
}
}
$mix_warehouse=array();
foreach(glob('download/mix_warehouse_mix*.txt') as $mix_warehouse_fa) {
if(substr($mix_warehouse_fa, 17, 8)>$t)
{
$mix_warehouse[] = $mix_warehouse_fa;
}
}
$sum_warehouse=array();
foreach(glob('download/sum_warehouse_mix*.txt') as $sum_warehouse_fa) {
if(substr($sum_warehouse_fa, 17, 8)>$t)
{
$sum_warehouse[] = $sum_warehouse_fa;
}
}
//warehouse_mix_label.pdf
$hk_warehouse_pdf = array();
foreach(glob('download/hk_warehouse_mix*.pdf') as $hk_warehouse_pdf_fn) {
if(substr($hk_warehouse_pdf_fn, 16, 8)>$t)
{
$hk_warehouse_pdf[] = $hk_warehouse_pdf_fn;
}
}
$jp_warehouse_pdf=array();
foreach(glob('download/jp_warehouse_mix*.pdf') as $jp_warehouse_pdf_fa) {
if(substr($jp_warehouse_pdf_fa, 16, 8)>$t)
{
$jp_warehouse_pdf[] = $jp_warehouse_pdf_fa;
}
}
$mix_warehouse_pdf=array();
foreach(glob('download/mix_warehouse_mix*.pdf') as $mix_warehouse_pdf_fa) {
if(substr($mix_warehouse_pdf_fa, 17, 8)>$t)
{
$mix_warehouse_pdf[] = $mix_warehouse_pdf_fa;
}
}
//pdf_mix
$hk_pdf = array();
foreach(glob('download/HK_print_Mix*.pdf') as $hk_pdf_fn) {
if(substr($hk_pdf_fn, 12, 8)>$t)
{
$hk_pdf[] = $hk_pdf_fn;
}
}
$jp_pdf=array();
foreach(glob('download/JP_print_Mix*.pdf') as $jp_pdf_fa) {
if(substr($jp_pdf_fa, 12, 8)>$t)
{
$jp_pdf[] = $jp_pdf_fa;
}
}
$mix_pdf=array();
foreach(glob('download/Mix_print_Mix*.pdf') as $mix_pdf_fa) {
if(substr($mix_pdf_fa, 13, 8)>$t)
{
$mix_pdf[] = $mix_pdf_fa;
}
}
//pdf_mix_A4
$hk_pdf_a4 = array();
foreach(glob('download/HK_print_Mix_A4_*.pdf') as $hk_pdf_a4_fn) {
if(substr($hk_pdf_a4_fn, 16, 8)>$t)
{
$hk_pdf_a4[] = $hk_pdf_a4_fn;