李林
2023-10-07 658d4927d468c47208fd012d9128b09249c07eff
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
package com.chinaztt.mes.aps.service;
 
import com.alibaba.fastjson.JSONObject;
import com.chinaztt.mes.aps.core.domain.OperationBo;
import com.chinaztt.mes.aps.entity.SceneTask;
import com.chinaztt.mes.aps.vo.GanttTaskVo;
import com.chinaztt.mes.production.entity.OperationTask;
import com.chinaztt.ztt.common.core.util.R;
 
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;
 
 
/**
 * @Author: zhangxy
 * @Date: 2020-10-09 10:35
 */
public interface ApsCoreService {
 
    /**
     * 保存场景甘特图
     *
     * @param task
     */
    void saveSceneTask(SceneTask task);
 
    /**
     * 查询工序
     *
     * @param operationId
     * @return
     */
    OperationBo queryOperation(Long operationId);
 
 
    /**
     * 区间查询
     *
     * @param sceneId
     * @param groupId
     * @param start
     * @param end
     * @return
     */
    JSONObject query(Long sceneId, Long groupId, LocalDate start, LocalDate end);
 
    /**
     * 区间查询
     *
     * @param sceneId
     * @param workStationList
     * @param start
     * @param end
     * @return
     */
    JSONObject loadGantt(Long sceneId, List<Long> workStationList, String workCenter, LocalDate start, LocalDate end, List<String> stateList);
 
    /**
     * 更新任务
     *
     * @param task
     * @return
     */
    Boolean updateTaskById(GanttTaskVo task);
 
    /**
     * 根据 工作站id 自动计算开始结束时间
     *
     * @param workstationId
     */
    OperationTask calOperationTaskTime(Long workstationId, Long partId, BigDecimal qty);
 
    /**
     * 自动选择机台并计算开始结束时间
     *
     * @param partId
     * @param qty
     * @return
     */
    OperationTask autoSetTime(String workCenter, Long partId, BigDecimal qty);
 
    /**
     * 根据ID删除任务
     *
     * @param id
     * @return
     */
    Boolean removeSceneTask(Long id);
 
    /**
     * 应用至实际场景
     *
     * @param sceneId
     * @return
     */
    R<Boolean> applyToReality(Long sceneId);
 
 
}