This repository has been archived on 2026-06-20. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
EDT/plugin/client_bb/wds.php
T
wsh5485 7e47ce238b chore: 添加多个图片和资源文件
添加了管理后台所需的图片资源、Excel文件、安装程序以及设计相关的图片文件
2025-06-15 13:04:37 +08:00

54 lines
1.9 KiB
PHP

<?php
//未订色
//by hehe 2014-08-12//
$use_layui_datatable="y";//使用标准layui datatable格式数据
$select_client_type="n";//dp:允许筛选店铺
//-------------------------------------------layui 数据表格格式
//--------------------------------表头
//支持参数field,title,width,rowspan,colspan,style(样式),sort(true|false),fixed(left,right)
$thead0="";
$thead0.="{\"field\":\"ord\",\"title\":\"次序\",\"width\":80,\"sort\":true},";
$thead0.="{\"field\":\"kh\",\"title\":\"款号\",\"width\":200},";
$thead0.="{\"field\":\"color\",\"title\":\"颜色\",\"width\":100}";
$thead="\"thead\":[{\"index\":0,\"content\":[".$thead0."]}],";
$json_data.=$thead;
//--------------------------------内容
//店铺查询条件
$con="";
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"]."-%')";
}
}
}
if($s_username){
$tbody="";
$q="select id,no,color,color_ka from ".$table_pre."kh where ka<>'y'";
$r=$db->query($q);
$list=1;
while($m=$db->fetch_array($r)){
$arr_color=explode(",",$m["color"]);
$arr_color_ka=explode(",",$m["color_ka"]);
for($i=0;$i<count($arr_color);$i++){
if(!in_array($arr_color[$i],$arr_color_ka)){
$check=get_db_msg("select count(*) 'num' from ".$table_pre."order where iid='".$m["id"]."' and color='".$arr_color[$i]."' ".$con);
if($check["num"]>0){
//已订
}else{
//未订
$tbody.="{\"ord\":\"".$list."\",\"kh\":\"<a href=javascript:dk_single(".$m["id"].")>".$m["no"]."</a>\",\"color\":\"".$arr_color[$i]."-".get_cate_title_no("color",$arr_color[$i])."\"},";
$list++;
}
}
}
}
}
$json_data.="\"tbody\":[".deel_end($tbody)."],";
?>