Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
Y
ypt_mgw_local
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
苏星豪
ypt_mgw_local
Commits
78c638b9
提交
78c638b9
authored
8月 09, 2024
作者:
张颂恩
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
调整经销商出入库查询
上级
b2ebeaa3
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
11 行增加
和
19 行删除
+11
-19
views.py
inventory/views.py
+6
-14
agent_stk_query.html
templates/inventory/agent_stk_query.html
+5
-5
没有找到文件。
inventory/views.py
浏览文件 @
78c638b9
...
...
@@ -7701,8 +7701,6 @@ def query_label(request):
return
JsonResponse
(
dt_data
)
# 2020/7/24 经销商出入库查询
# 2022/9/28 Jonathan 重写查询逻辑
@tj_login_required
...
...
@@ -7742,7 +7740,9 @@ def agent_stk_query(request):
h,
P,
b.remark,
b.company_id
b.company_id,
coalesce((select name from company_salesdivision where id = c.division_id and is_delete=false),''),
coalesce((select name from company_subsaldivision where id = c.sub_division_id and is_delete=false),'')
FROM
(
SELECT
...
...
@@ -7780,13 +7780,13 @@ def agent_stk_query(request):
vtype_id
) A
LEFT JOIN logistics.inventory_batch b ON A.batch_id = b.id
LEFT JOIN logistics.company_company c ON b.company_id = c.id
order by batch_id
"""
cur
.
execute
(
s
)
data
=
[]
for
r
in
cur
.
fetchall
():
#南海球杆
if
cid
==
194378
:
data
.
append
([
"<a href='inventory/agent/details/"
+
str
(
r
[
0
])
+
"/'>"
+
r
[
1
]
+
"</a>"
,
# 日期
...
...
@@ -7800,21 +7800,13 @@ def agent_stk_query(request):
r
[
11
],
# 备注
])
else
:
company_id
=
r
[
12
]
cur
.
execute
(
f
"""
select
coalesce((select name from company_salesdivision where id = c.division_id and is_delete=false),''),
coalesce((select name from company_subsaldivision where id = c.sub_division_id and is_delete=false),'')
from logistics.company_company c where id= {company_id}
"""
)
row
=
cur
.
fetchone
()
data
.
append
([
"<a href='inventory/agent/details/"
+
str
(
r
[
0
])
+
"/'>"
+
r
[
1
]
+
"</a>"
,
# 日期
r
[
2
],
# 单据类别
r
[
3
],
# 单据编号
r
[
4
],
# 产品名称
r
ow
[
0
],
# 战区
r
ow
[
1
],
#
分区
r
[
13
],
# 战区
r
[
14
],
#
分区
r
[
5
],
# 操作方
r
[
6
],
# 客户名称
r
[
7
],
# 操作人
...
...
templates/inventory/agent_stk_query.html
浏览文件 @
78c638b9
...
...
@@ -125,9 +125,9 @@
<th
style=
'width:10%'
>
{% trans "日期时间" %}
</th>
<th
style=
'width:10%'
>
{% trans "单据类别" %}
</th>
<th
style=
'width:6%'
>
{% trans "单据编号" %}
</th>
<th
style=
'width:
1
0%'
>
{% trans "产品名称" %}
</th>
<th>
{% trans "
所属
战区" %}
</th>
<th>
{% trans "
所属
分区" %}
</th>
<th
style=
'width:
2
0%'
>
{% trans "产品名称" %}
</th>
<th>
{% trans "战区" %}
</th>
<th>
{% trans "分区" %}
</th>
<th>
{% trans "操作商" %}
</th>
<th>
{% trans "客户名称" %}
</th>
<th
style=
'width:6%'
>
{% trans "操作人" %}
</th>
...
...
@@ -143,8 +143,8 @@
<th><input
type=
"text"
placeholder=
"{% trans "
单据类别"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
单据编号"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
产品名称"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
所属
战区"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
所属
分区"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
战区"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
分区"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
操作商"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
客户名称"
%}"
></th>
<th><input
type=
"text"
placeholder=
"{% trans "
操作人"
%}"
></th>
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论