|
@@ -32,6 +32,7 @@
|
|
|
<el-button type="primary" icon="edit" @click="pd_gxclhconClick" class="bt">工序产量核查</el-button>
|
|
<el-button type="primary" icon="edit" @click="pd_gxclhconClick" class="bt">工序产量核查</el-button>
|
|
|
<el-button type="primary" icon="edit" @click="pd_lcdlistonClick" class="bt">流程单查询</el-button>
|
|
<el-button type="primary" icon="edit" @click="pd_lcdlistonClick" class="bt">流程单查询</el-button>
|
|
|
|
|
|
|
|
|
|
+
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-form>
|
|
</el-form>
|
|
|
|
|
|
|
@@ -241,14 +242,13 @@
|
|
|
</div>
|
|
</div>
|
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
|
|
|
|
-
|
|
|
|
|
</div>
|
|
</div>
|
|
|
</layout-header>
|
|
</layout-header>
|
|
|
|
|
|
|
|
<layout>
|
|
<layout>
|
|
|
<layout-sider :resize-directions="['right']" :width="190" style="margin-right: 10px;">
|
|
<layout-sider :resize-directions="['right']" :width="190" style="margin-right: 10px;">
|
|
|
<div class="JKWTree-tree" style="height: 200px">
|
|
<div class="JKWTree-tree" style="height: 200px">
|
|
|
- <el-tree :data="treeData" :props="defaultProps" :current-node-key="currentNodeKey" @node-click="handleNodeClick"></el-tree>
|
|
|
|
|
|
|
+ <el-tree :data="treeData" :props="defaultProps" class="treecolor" :current-node-key="currentNodeKey" @node-click="handleNodeClick"></el-tree>
|
|
|
</div>
|
|
</div>
|
|
|
</layout-sider>
|
|
</layout-sider>
|
|
|
<layout-content>
|
|
<layout-content>
|
|
@@ -691,20 +691,31 @@ const tableData = ref([]);
|
|
|
const _machine = ref(null);
|
|
const _machine = ref(null);
|
|
|
const treeType = ref('customTree') // dataTree // 计划中,排产中 ,dataTree 车间
|
|
const treeType = ref('customTree') // dataTree // 计划中,排产中 ,dataTree 车间
|
|
|
const handleNodeClick = async (node) => {
|
|
const handleNodeClick = async (node) => {
|
|
|
- // console.log(node)
|
|
|
|
|
- // console.log(node['$treeNodeId'])
|
|
|
|
|
|
|
+ // 取消所有节点的颜色
|
|
|
|
|
+ const allNodes = document.querySelectorAll('.treecolor .el-tree-node');
|
|
|
|
|
+ allNodes.forEach(node => {
|
|
|
|
|
+ node.querySelector('.el-tree-node__label').style.color = '';
|
|
|
|
|
+ });
|
|
|
|
|
+ // 获取点击的节点
|
|
|
|
|
+ const clickedNodeId = node['$treeNodeId'];
|
|
|
|
|
+ console.log(clickedNodeId);
|
|
|
|
|
+ const clickedNode = document.querySelector(`.treecolor .el-tree-node[data-key="${clickedNodeId}"]`);
|
|
|
|
|
+ if (clickedNode) {
|
|
|
|
|
+ console.log(clickedNode);
|
|
|
|
|
+ // 给当前点击的节点改变颜色
|
|
|
|
|
+ clickedNode.querySelector('.el-tree-node__label').style.color = 'red';
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
if (node.type && node.type === '__customer') {
|
|
if (node.type && node.type === '__customer') {
|
|
|
treeType.value = 'customTree'
|
|
treeType.value = 'customTree'
|
|
|
schandleNodeClick(node)
|
|
schandleNodeClick(node)
|
|
|
} else if (!node.children) {
|
|
} else if (!node.children) {
|
|
|
treeType.value = 'dataTree'
|
|
treeType.value = 'dataTree'
|
|
|
- const custom_code = node.label;
|
|
|
|
|
// 使用字符串分割获取#前面的数据
|
|
// 使用字符串分割获取#前面的数据
|
|
|
- const dataBeforeHash = custom_code.split('#')[0].trim();
|
|
|
|
|
- _machine.value = dataBeforeHash + '#';
|
|
|
|
|
- console.log('机台' + _machine.value)
|
|
|
|
|
|
|
+ _machine.value = node.label.split('#')[0].trim() + '#';
|
|
|
|
|
+ console.log('机台-------' + _machine.value)
|
|
|
const zhubiao = await MachineWorkOrderList({ machine:_machine.value})
|
|
const zhubiao = await MachineWorkOrderList({ machine:_machine.value})
|
|
|
- console.log(zhubiao)
|
|
|
|
|
|
|
+ // console.log(zhubiao)
|
|
|
chejianData.value = zhubiao.data['排程'];
|
|
chejianData.value = zhubiao.data['排程'];
|
|
|
chejianfuData.value = zhubiao.data['制程'];
|
|
chejianfuData.value = zhubiao.data['制程'];
|
|
|
}
|
|
}
|
|
@@ -1611,10 +1622,7 @@ const rowContextMenu = (row) => {
|
|
|
:deep(.hui-plan-usage-low div) {
|
|
:deep(.hui-plan-usage-low div) {
|
|
|
color: #8c939d !important;
|
|
color: #8c939d !important;
|
|
|
}
|
|
}
|
|
|
-/*点击车间机台*/
|
|
|
|
|
-:deep(.el-background-color) {
|
|
|
|
|
- color: red !important;
|
|
|
|
|
-}
|
|
|
|
|
|
|
+
|
|
|
/*工序状态更正颜色【蓝色】*/
|
|
/*工序状态更正颜色【蓝色】*/
|
|
|
:deep(.lan-plan-usage-low div) {
|
|
:deep(.lan-plan-usage-low div) {
|
|
|
color: blue !important;
|
|
color: blue !important;
|