Commit 77da1d2c authored by 谢希宇's avatar 谢希宇

Submit by Strive

Date 2021/04/115
Project End
parent 60e88cfe
......@@ -400,7 +400,7 @@
"aTargets": [3],
"mData": "userName",
"mRender": function (a, b, c, d) {
if (c) {
if (c.userName) {
return c.userName.slice(0, 1) + '*' + c.userName.slice(2, c.userName.length);
} else {
return null;
......
......@@ -151,8 +151,8 @@
<th style="width: 50px">大区</th>
<th style="width: 50px">省份</th>
<th style="width: 50px">城市</th>
<th style="width: 60px">销售代表</th>
<th style="width: 65px">医院</th>
<th style="width: 60px">销售代表</th>
<th style="width: 50px">科室</th>
<th style="width: 60px">医生姓名</th>
<th style="width: 60px">医生职称</th>
......@@ -277,10 +277,10 @@
"mData": "city"
},
{
"mData": "salesRepresent"
"mData": "hospital"
},
{
"mData": "hospital"
"mData": "salesRepresent"
},
{
"mData": "department"
......
......@@ -294,18 +294,18 @@
<!--查询报表人员信息-->
<select id="selectReportPeopleInfo" resultMap="resultMapPeopleInfo" parameterType="java.util.Map">
SELECT
product.product_name productName,
detail.drugs_num drugsNum,
ord.number orderNumber,
consult.consult_id consultNumber,
CONVERT ( AES_DECRYPT( consult.user_name, 'aideakey' ) USING UTF8 ) userName,
CONVERT ( AES_DECRYPT( consult.phone, 'aideakey' ) USING UTF8 ) phone,
qyuser.`name` cfDoctor,
org1.org_name cfHospital,
ord.pay_time fkTime,
waybill.send_express_date fhTime,
waybill.accept_express_date sjTime,
ord.openid openId
product.common_name productName,
detail.drugs_num drugsNum,
ord.number orderNumber,
consult.consult_id consultNumber,
CONVERT ( AES_DECRYPT( consult.user_name, 'aideakey' ) USING UTF8 ) userName,
CONVERT ( AES_DECRYPT( consult.phone, 'aideakey' ) USING UTF8 ) phone,
qyuser.`name` cfDoctor,
org1.org_name cfHospital,
ord.pay_time fkTime,
waybill.send_express_date fhTime,
waybill.accept_express_date sjTime,
ord.openid openId
FROM
t_order_details detail
LEFT JOIN t_aidea_product product ON product.id = detail.drugs_id AND product.del_flag = 0
......
-- 订单已付款视图
create view view_order_record as
SELECT
o.id, --订单主键
o.number, --订单编码
o.total_amount, --订单总金额
od.drugs_num, --订单数量
sb.drugs_num split_num, --拆分数量
sb.drugs_batchno, --拆分批次号
p.product_name, --产品名称
p.product_number, --产品编码
o.create_time, --创建时间
o.pay_time --付款时间
FROM
t_order o
LEFT JOIN t_order_details od ON o.id = od.order_id AND od.del_flag = 0
LEFT JOIN t_order_split_batch sb ON o.id = sb.order_id AND sb.del_flag = 0
LEFT JOIN t_aidea_product p ON od.drugs_id = p.id AND p.del_flag = 0
WHERE o.status IN ('2', '3', '4') -- 待发货、待收货、已完成订单
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment