Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
doc_wei
Skyeye
提交
d27ba790
S
Skyeye
项目概览
doc_wei
/
Skyeye
通知
1182
Star
154
Fork
127
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
S
Skyeye
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
d27ba790
编写于
7月 20, 2024
作者:
L
LAPTOP-UV1MNL38\18023
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'company_server' of
https://gitee.com/doc_wei01/skyeye
into company_server
上级
53710c4d
c76dadaf
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
50 addition
and
97 deletion
+50
-97
erp-produce/src/main/resources/template/js/departmentMachining/departmentMachiningList.js
...emplate/js/departmentMachining/departmentMachiningList.js
+3
-3
erp-produce/src/main/resources/template/js/departmentMachining/machiningGantt.js
...sources/template/js/departmentMachining/machiningGantt.js
+47
-79
erp-produce/src/main/resources/template/tpl/departmentMachining/machiningGantt.html
...rces/template/tpl/departmentMachining/machiningGantt.html
+0
-15
未找到文件。
erp-produce/src/main/resources/template/js/departmentMachining/departmentMachiningList.js
浏览文件 @
d27ba790
var
rowId
=
""
;
var
rowId
=
""
;
layui
.
config
({
layui
.
config
({
...
@@ -111,11 +110,11 @@ layui.config({
...
@@ -111,11 +110,11 @@ layui.config({
// 甘特图
// 甘特图
function
gantt
(
data
)
{
function
gantt
(
data
)
{
_openNewWindows
({
parent
.
_openNewWindows
({
url
:
"
../../tpl/departmentMachining/machiningGantt.html?id=
"
+
data
.
id
,
url
:
"
../../tpl/departmentMachining/machiningGantt.html?id=
"
+
data
.
id
,
title
:
"
车间任务安排甘特图
"
,
title
:
"
车间任务安排甘特图
"
,
pageId
:
"
machiningGantt
"
,
pageId
:
"
machiningGantt
"
,
area
:
[
'
90vw
'
,
'
9
0vh
'
],
area
:
[
'
100vw
'
,
'
10
0vh
'
],
callBack
:
function
(
refreshCode
)
{
callBack
:
function
(
refreshCode
)
{
winui
.
window
.
msg
(
systemLanguage
[
"
com.skyeye.successfulOperation
"
][
languageType
],
{
icon
:
1
,
time
:
2000
});
winui
.
window
.
msg
(
systemLanguage
[
"
com.skyeye.successfulOperation
"
][
languageType
],
{
icon
:
1
,
time
:
2000
});
loadTable
();
loadTable
();
...
@@ -134,6 +133,7 @@ layui.config({
...
@@ -134,6 +133,7 @@ layui.config({
loadTable
();
loadTable
();
}});
}});
}
}
//转补料单
//转补料单
function
processingToSupplementMaterials
(
data
){
function
processingToSupplementMaterials
(
data
){
_openNewWindows
({
_openNewWindows
({
...
...
erp-produce/src/main/resources/template/js/departmentMachining/machiningGantt.js
浏览文件 @
d27ba790
...
@@ -10,37 +10,26 @@ layui.config({
...
@@ -10,37 +10,26 @@ layui.config({
form
=
layui
.
form
;
form
=
layui
.
form
;
var
id
=
GetUrlParam
(
"
id
"
);
var
id
=
GetUrlParam
(
"
id
"
);
let
noteList
=
[];
// 根据id查询加工单信息
// 根据id查询加工单信息
AjaxPostUtil
.
request
({
url
:
sysMainMation
.
erpBasePath
+
"
queryMachinForGanttById
"
,
params
:
{
id
:
id
},
type
:
'
json
'
,
method
:
'
GET
'
,
callback
:
function
(
json
)
{
AjaxPostUtil
.
request
({
url
:
sysMainMation
.
erpBasePath
+
"
queryMachinForGanttById
"
,
params
:
{
id
:
id
},
type
:
'
json
'
,
method
:
'
GET
'
,
callback
:
function
(
json
)
{
console
.
log
(
json
)
matchingLanguage
();
matchingLanguage
();
form
.
render
();
form
.
render
();
renderPanel
();
renderPanel
();
// render();
gantt
.
clearAll
();
//清空缓存
let
nodeList
=
json
.
bean
.
node
;
if
(
isNull
(
nodeList
)
||
nodeList
.
length
==
0
)
{
return
;
}
$
.
each
(
nodeList
,
function
(
i
,
item
)
{
item
.
start_date
=
new
Date
(
item
.
start_date
);
item
.
end_date
=
new
Date
(
item
.
end_date
);
});
let
linkList
=
json
.
bean
.
link
;
if
(
isNull
(
linkList
)
||
linkList
.
length
==
0
)
{
linkList
=
[];
}
// 解析
gantt
.
parse
({
data
:
nodeList
,
links
:
linkList
});
}});
gantt
.
config
.
start_date
=
new
Date
(
json
.
bean
.
mathinTime
.
start_time
);
gantt
.
config
.
end_date
=
new
Date
(
json
.
bean
.
mathinTime
.
end_time
);
gantt
.
clearAll
();
//清空缓存
// 解析
noteList
=
json
.
bean
.
node
;
gantt
.
parse
({
data
:
json
.
bean
.
node
,
links
:
json
.
bean
.
link
});
}});
function
renderPanel
()
{
function
renderPanel
()
{
document
.
getElementById
(
'
device_load
'
).
style
.
cssText
=
'
height:
'
+
(
$
(
window
).
height
()
-
140
)
+
'
px
'
;
document
.
getElementById
(
'
device_load
'
).
style
.
cssText
=
'
height:
'
+
$
(
window
).
height
(
)
+
'
px
'
;
}
}
$
(
window
).
resize
(
function
()
{
$
(
window
).
resize
(
function
()
{
renderPanel
();
renderPanel
();
...
@@ -60,12 +49,30 @@ layui.config({
...
@@ -60,12 +49,30 @@ layui.config({
align
:
"
center
"
,
align
:
"
center
"
,
tree
:
true
,
tree
:
true
,
resize
:
true
resize
:
true
},
{
name
:
"
types
"
,
label
:
"
类型
"
,
width
:
60
,
align
:
"
center
"
,
resize
:
true
,
template
:
function
(
item
)
{
if
(
item
.
types
==
"
project
"
)
{
return
"
<span style='color: #009688; font-weight: bold;'>产品</span>
"
;
}
return
"
<span style='color: #FFB800;'>工序</span>
"
;
}
},
{
},
{
name
:
"
start_date
"
,
name
:
"
start_date
"
,
label
:
"
开始日期
"
,
label
:
"
开始日期
"
,
width
:
100
,
width
:
100
,
align
:
"
center
"
,
align
:
"
center
"
,
resize
:
true
resize
:
true
},
{
name
:
"
end_date
"
,
label
:
"
结束日期
"
,
width
:
100
,
align
:
"
center
"
,
resize
:
true
},
{
},
{
name
:
"
duration
"
,
name
:
"
duration
"
,
label
:
"
持续时间
"
,
label
:
"
持续时间
"
,
...
@@ -73,6 +80,7 @@ layui.config({
...
@@ -73,6 +80,7 @@ layui.config({
align
:
"
center
"
,
align
:
"
center
"
,
resize
:
true
resize
:
true
}];
}];
// 是否可以编辑
gantt
.
config
.
readonly
=
true
;
gantt
.
config
.
readonly
=
true
;
gantt
.
config
.
row_height
=
40
;
gantt
.
config
.
row_height
=
40
;
gantt
.
config
.
scale_height
=
50
;
gantt
.
config
.
scale_height
=
50
;
...
@@ -84,6 +92,18 @@ layui.config({
...
@@ -84,6 +92,18 @@ layui.config({
gantt
.
attachEvent
(
"
onTaskDblClick
"
,
function
(
id
,
e
)
{
gantt
.
attachEvent
(
"
onTaskDblClick
"
,
function
(
id
,
e
)
{
return
false
;
return
false
;
});
});
gantt
.
attachEvent
(
"
onTaskClick
"
,
function
(
id
,
e
){
// 这里的代码会在节点被点击时执行
// id 参数是被点击的任务的ID
// e 参数是点击事件的事件对象
let
item
=
getInPoingArr
(
noteList
,
"
id
"
,
id
,
null
);
if
(
item
.
types
!=
"
project
"
)
{
console
.
log
(
item
)
alert
(
"
Task with ID
"
+
id
+
"
was clicked
"
);
}
// 返回true以允许默认行为继续,返回false可以阻止默认行为
return
true
;
});
gantt
.
config
.
show_tasks_outside_timescale
=
true
;
gantt
.
config
.
show_tasks_outside_timescale
=
true
;
gantt
.
plugins
({
gantt
.
plugins
({
auto_scheduling
:
true
,
//自动排程
auto_scheduling
:
true
,
//自动排程
...
@@ -93,8 +113,7 @@ layui.config({
...
@@ -93,8 +113,7 @@ layui.config({
gantt
.
config
.
layout
=
{
gantt
.
config
.
layout
=
{
css
:
"
gantt_container
"
,
css
:
"
gantt_container
"
,
cols
:
[{
cols
:
[{
width
:
400
,
width
:
500
,
min_width
:
300
,
rows
:
[
rows
:
[
{
{
view
:
"
grid
"
,
view
:
"
grid
"
,
...
@@ -124,58 +143,7 @@ layui.config({
...
@@ -124,58 +143,7 @@ layui.config({
};
};
gantt
.
init
(
"
device_load
"
);
gantt
.
init
(
"
device_load
"
);
gantt
.
i18n
.
setLocale
(
"
cn
"
);
//使用中文
gantt
.
i18n
.
setLocale
(
"
cn
"
);
//使用中文
// function render() {
// let milestoneId = $("#milestoneId").val();
// if (isNull(milestoneId)) {
// winui.window.msg("请选择产品", {icon: 2, time: 2000});
// return false;
// }
// let params = {
// id: objectId,
// // objectKey: objectKey,
// // holderId: milestoneId,
// // type: $("#type .plan-select").attr("data-type")
// };
// var tem = getInPoingArr(milestoneList, "id", milestoneId, null);
// gantt.config.start_date = new Date(tem.startTime);
// gantt.config.end_date = new Date(tem.endTime);
// console.log(999)
// AjaxPostUtil.request({url: sysMainMation.erpBasePath + "queryMachinForGanttById", params: params, type: 'json', method: 'GET', callback: function (json) {
// gantt.clearAll(); //清空缓存
// let nodeList = json.bean.node;
// if (isNull(nodeList) || nodeList.length == 0) {
// return;
// }
// $.each(nodeList, function (i, item) {
// item.start_date = new Date(item.start_date);
// item.end_date = new Date(item.end_date);
// });
// let linkList = json.bean.link;
// if (isNull(linkList) || linkList.length == 0) {
// linkList = [];
// }
// // 解析
// gantt.parse({
// data: nodeList,
// links: linkList
// });
// }});
// }
$
(
"
body
"
).
on
(
"
click
"
,
"
.type-btn
"
,
function
(
e
)
{
$
(
this
).
parent
().
find
(
'
.type-btn
'
).
removeClass
(
"
plan-select
"
);
$
(
this
).
addClass
(
"
plan-select
"
);
render
();
});
form
.
on
(
'
submit(formSearch)
'
,
function
(
data
)
{
if
(
winui
.
verifyForm
(
data
.
elem
))
{
render
();
}
return
false
;
});
exports
(
'
machiningGantt
'
,
{});
exports
(
'
machiningGantt
'
,
{});
});
});
\ No newline at end of file
erp-produce/src/main/resources/template/tpl/departmentMachining/machiningGantt.html
浏览文件 @
d27ba790
...
@@ -39,21 +39,6 @@
...
@@ -39,21 +39,6 @@
</head>
</head>
<body>
<body>
<div
class=
"txtcenter"
style=
"margin: 0 auto; padding-top: 10px;"
>
<form
class=
"layui-form layui-form-pane"
action=
""
autocomplete=
"off"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
产品
</label>
<div
class=
"layui-input-inline"
>
<select
lay-filter=
"milestoneId"
lay-search=
""
id=
"milestoneId"
>
</select>
</div>
<button
type=
"reset"
class=
"layui-btn layui-btn-primary list-form-search"
><language
showName=
"com.skyeye.reset"
></language></button>
<button
class=
"layui-btn list-form-search"
lay-submit
lay-filter=
"formSearch"
><language
showName=
"com.skyeye.search2"
></language></button>
</div>
</div>
</form>
</div>
<div
style=
"margin: auto 10px;"
>
<div
style=
"margin: auto 10px;"
>
<div
id=
"device_load"
style=
"width: 100%;"
></div>
<div
id=
"device_load"
style=
"width: 100%;"
></div>
</div>
</div>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录