chore: 添加多个图片和资源文件

添加了管理后台所需的图片资源、Excel文件、安装程序以及设计相关的图片文件
This commit is contained in:
2025-06-15 13:04:37 +08:00
parent 1e61dc3970
commit 7e47ce238b
13220 changed files with 1377028 additions and 0 deletions
+193
View File
@@ -0,0 +1,193 @@
<?php
//自定义1维报表
//可配置参数:keyword_zd1|category|横向纬度,keyword_zd2|brand|筛选项,icon|menu_icon_table|菜单图标
//2019-12-23 by hehe
//-----参数配置
//菜单图标
$icon=get_plugin_set("icon","menu_icon_table");//支持以下目录的图标ipad/images/menu_icon_*.png
//横向纬度
$zd1=get_plugin_set("keyword_zd1","category");
//筛选项
$zd2=get_plugin_set("keyword_zd2","brand");
//
$select_client_type="y";//dp:允许筛选店铺
$use_layui_datatable="n";//使用标准layui datatable格式数据
//店铺查询条件
$con=" ka<>'y'";
if($msg_client["face"]=="4"){
$s_username=$msg_client["username"];
$con=" and uid='".$msg_client["id"]."'";
}else{
if($s_username){
$m2=get_db_msg("select id,face,path from ".$table_pre."client where username='".$s_username."'");
if($m2["face"]=="4"){
$con=" and uid='".$m2["id"]."'";
}else{
$con=" and (upath='".$m2["path"]."-".$m2["id"]."' or upath like '".$m2["path"]."-".$m2["id"]."-%')";
}
}else if($msg_client["face"]=="2"){
//区经角色所有客户
$con=get_qj_ucon_all($msg_client["charge_path_real"]);
}else{
//代理角色所有客户
$con=" and (upath='".$msg_client["path"]."-".$msg_client["id"]."' or upath like '".$msg_client["path"]."-".$msg_client["id"]."-%')";
}
}
//----选项
if($zd2){
$zd_title2=get_cate_title_no("arr_select",$zd2);
$var="s_".$zd2;
$q="select * from ".$table_pre."keyword where cate='".$zd2."' order by no";
$r=$db->query($q);
$op="";
while($m=$db->fetch_array($r)){
$op.="{\"no\":\"".$m["no"]."\",\"title\":\"".$m["title"]."\"},";
}
$select="{\"name\":\"s_".$zd2."\",\"title\":\"".$zd_title2."\",\"value\":\"".$$var."\",\"op\":[".deel_end($op)."]},";
}
if($zd1){
$zd_title1=get_cate_title_no("arr_select",$zd1);
$con_kh=" and ka<>'y'";
$var="s_".$zd2;
if($$var){
$con_kh.=" and ".$zd2."='".$$var."'";
$con.=" and ".$zd2."='".$$var."'";
}
$content_data.="<table id='tabledetail' class='cell-border nowrap' width='100%' lay-filter='layui_table' cellspacing='0' cellpadding='0' border='0' class='layui-table'><thead>";
//表头第一行
$content_data.="<tr>";
$content_data.="<th align='center' rowspan='2'><strong>".$zd_title1."</strong></th>";
$content_data.="<th align='center' rowspan='2'><strong>均价</strong></th>";
$content_data.="<th align='center' colspan='2'><strong>设计款数</strong></th>";
$content_data.="<th align='center' colspan='2'><strong>已订款数</strong></th>";
$content_data.="<th align='center' colspan='2'><strong>已订件数</strong></th>";
$content_data.="<th align='center' colspan='2'><strong>吊牌金额</strong></th>";
$content_data.="<th align='center' colspan='2'><strong>结算金额</strong></th>";
$content_data.="</tr>";
//表头第二行
$content_data.="<tr>";
$content_data.="<th align='center'><strong>款数</strong></th><th align='center'><strong>占比</strong></th><th align='center'><strong>款数</strong></th><th align='center'><strong>占比</strong></th><th align='center'><strong>件数</strong></th><th align='center'><strong>占比</strong></th><th align='center'><strong>金额</strong></th><th align='center'><strong>占比</strong></th><th align='center'><strong>金额</strong></th><th align='center'><strong>占比</strong></th>";
$content_data.="</tr>";
$content_data.="</thead>";
//取得总款数
$tmp=get_db_msg("select count(*) 'num' from ".$table_pre."kh where ".$zd1."<>''".$con_kh);
$total_ks=$tmp["num"];
//取得总款色数
$total_sku=0;
$q2="select no,color,color_ka from ".$table_pre."kh where ".$zd1."<>''".$con_kh;
$r2=$db->query($q2);
while($m2=$db->fetch_array($r2)){
$arr1=explode(",",$m2["color"]);
$arr2=explode(",",$m2["color_ka"]);
for($i1=0;$i1<count($arr1);$i1++){
if(!in_array($arr1[$i1],$arr2))
$total_sku++;
}
}
//取得总均价
$tmp=get_db_msg("select sum(price)/count(*) 'jj' from ".$table_pre."kh where ".$zd1."<>''".$con_kh);
$price_jj=keep_float($tmp["jj"],1);
//取得已订总件数和金额
$q="select sum(num) 'num',sum(je) 'je',sum(jsje) 'jsje' from ".$table_pre."order where ".$zd1."<>'' ".$con;
$tmp=get_db_msg($q);
$total_yd_js=$tmp["num"];
$total_yd_je=$tmp["je"];
$total_yd_jsje=$tmp["jsje"];
//取得已订总款数
$tmp1=get_db_msg("select count(distinct no) 'num' from ".$table_pre."order where ".$zd1."<>'' ".$con);
$total_yd_ks=$tmp1["num"];
//取得已订总款色数
$tmp1=get_db_msg("select count(distinct no,color) 'num' from ".$table_pre."order where ".$zd1."<>'' ".$con);
$total_yd_sku=$tmp1["num"];
//
$tb_data_x="";
$tb_data_y=",";
//
$tbody_str="";
$q="select * from ".$table_pre."keyword where cate='".$zd1."' order by no";
$r=$db->query($q);
$count=0;
while($m=$db->fetch_array($r)){
$list=$count+1;
//------取得款数
$tmp=get_db_msg("select count(distinct no) 'num' from ".$table_pre."order where ".$zd1."='".$m["no"]."'".$con);
$tmp_yd_ks=$tmp["num"];
$tmp=get_db_msg("select count(*) 'num' from ".$table_pre."kh where ".$zd1."='".$m["no"]."'".$con_kh);
$tmp_z_ks=$tmp["num"];
//取得款色
$tmp=get_db_msg("select count(distinct no,color) 'num' from ".$table_pre."order where ".$zd1."='".$m["no"]."'".$con);
$tmp_yd_sku=$tmp["num"];
$tmp_z_sku=0;
$q2="select no,color,color_ka from ".$table_pre."kh where ".$zd1."='".$m["no"]."'".$con_kh;
$r2=$db->query($q2);
while($m2=$db->fetch_array($r2)){
$n1=count(explode(",",$m2["color"]));
$n2=trim($m2["color_ka"])?count(explode(",",$m2["color_ka"])):0;
$tmp_z_sku+=$n1-$n2;
}
//取得数量
$tmp=get_db_msg("select sum(num) 'num',sum(je) 'je',sum(jsje) 'jsje' from ".$table_pre."order where id>0 and ".$zd1."='".$m["no"]."'".$con);
$tmp_yd_js=$tmp["num"];
$tmp_yd_je=$tmp["je"];
$tmp_yd_jsje=$tmp["jsje"];
if($tmp_z_ks>0){
//取得均价
$tmp=get_db_msg("select sum(price)/count(*) 'jj' from ".$table_pre."kh where ".$zd1."='".$m["no"]."'".$con_kh);
$content_data.="<tr>";
$content_data.="<td align='center'>".$m["title"]."</td>";
$content_data.="<td align='center'>".keep_float($tmp["jj"],1)."</td>";//均价
$content_data.="<td align='center'>".$tmp_z_ks."</td>";//设计款数
$content_data.="<td align='center'>".deel_bfb($tmp_z_ks,$total_ks)."</td>";//设计款数占比
$content_data.="<td align='center'>".$tmp_yd_ks."</td>";//已订款数
$content_data.="<td align='center'>".deel_bfb($tmp_yd_ks,$total_yd_ks)."</td>";//已订款数占比
$content_data.="<td align='center'>".$tmp_yd_js."</td>";//已订件数
$content_data.="<td align='center'>".deel_bfb($tmp_yd_js,$total_yd_js)."</td>";//已订件数占比
$content_data.="<td align='center'>".deel_num($tmp_yd_je)."</td>";//吊牌金额
$content_data.="<td align='center'>".deel_bfb($tmp_yd_je,$total_yd_je)."</td>";//吊牌金额占比
$content_data.="<td align='center'>".deel_num($tmp_yd_jsje)."</td>";//结算金额
$content_data.="<td align='center'>".deel_bfb($tmp_yd_jsje,$total_yd_jsje)."</td>";//结算金额占比
$content_data.="</tr>";
$count++;
//
$tb_data_x.=$m["title"].",";
$tb_data_y.=str_replace("%","",deel_bfb($tmp_yd_js,$total_yd_js)).",";
}
}
//合计
$content_data.="<tr bgcolor='#f0f0f0'>";
$content_data.="<td align='center'>合计</td>";//均价
$content_data.="<td align='center'>".$price_jj."</td>";//均价
$content_data.="<td align='center'>".$total_ks."</td>";//设计款数
$content_data.="<td align='center'>&nbsp;</td>";//设计款数占比
$content_data.="<td align='center'>".$total_yd_ks."</td>";//已订款数
$content_data.="<td align='center'>&nbsp;</td>";//已订款数占比
$content_data.="<td align='center'>".$total_yd_js."</td>";//已订件数
$content_data.="<td align='center'>&nbsp;</td>";//已订件数占比
$content_data.="<td align='center'>".deel_num($total_yd_je)."</td>";//吊牌金额
$content_data.="<td align='center'>&nbsp;</td>";//吊牌金额占比
$content_data.="<td align='center'>".deel_num($total_yd_jsje)."</td>";//结算金额
$content_data.="<td align='center'>&nbsp;</td>";//结算金额占比
$content_data.="</tr>";
//图
$tb_data_y=deel_end($tb_data_y);
$tb_data_x=deel_end($tb_data_x);
/*
$json_data.="\"chart_title\":\"\",";
$json_data.="\"chart_type\":\"pie\",";
$json_data.="\"chart_data_x\":\"".$tb_data_x."\",";
$json_data.="\"chart_data_y\":\"".$tb_data_y."\",";
*/
$content_data.="</tbody>";
$content_data.="</table>";
$content_data1="<table width='100%' cellspacing='0' cellpadding='0' border='0'>";
$content_data1.="<tr><td><iframe id='frame_chart' src='chart.php?t=pie&data_x=".$tb_data_x."&data_y=".$tb_data_y."&title=' width='100%' style='height:400px;position:static;'></iframe></td></tr>";
$content_data1.="<tr><td>".$content_data."</td></tr>";
$content_data1.="</table>";
$json_data.="\"table_html\":\"".$content_data1."\",";
}else{
$json_data.="\"table_html\":\"请定义字段值!\",";
}
//echo $con."<br>";
//echo $con_kh."<Br>";
?>