瀏覽代碼

fixed: 修改sql节点传输数据bug

liuyang 2 年之前
父節點
當前提交
a8f98943cc

+ 3 - 3
src/router.ts

@ -18,7 +18,7 @@ const routes: Array<RouteRecordRaw> = [
18 18
        name: 'SystemList',
19 19
        component: () => import('./views/flow/SystemList.vue'),
20 20
        meta: {
21
          breadcrumb: [{ name: '系统管理' }]
21
          breadcrumb: [{ name: '流程编排' }]
22 22
        }
23 23
      },
24 24
      {
@ -28,7 +28,7 @@ const routes: Array<RouteRecordRaw> = [
28 28
        meta: {
29 29
          breadcrumb: [
30 30
            {
31
              name: '系统管理',
31
              name: '流程编排',
32 32
              to: {
33 33
                name: 'SystemList'
34 34
              }
@ -44,7 +44,7 @@ const routes: Array<RouteRecordRaw> = [
44 44
        meta: {
45 45
          breadcrumb: [
46 46
            {
47
              name: '系统管理',
47
              name: '流程编排',
48 48
              to: {
49 49
                name: 'SystemList'
50 50
              }

+ 5 - 4
src/views/_components/panel/PanelGlobal.vue

@ -135,7 +135,7 @@ import { computed, reactive, ref, watch } from 'vue';
135 135
// import XLSX from 'xlsx';
136 136
// 模型属性引入
137 137
import { useRoute } from 'vue-router';
138
import { useStore } from 'vuex';
138
// import { useStore } from 'vuex';
139 139
// eslint-disable-next-line no-unused-vars
140 140
import ImportModel from './global/ImportModel.vue';
141 141
import CustomDetailList from './global/CustomDetailList.vue';
@ -146,10 +146,11 @@ import { getModelListApi } from '../../../api/flow';
146 146
const activeName = ref('customAttrs');
147 147
const route = useRoute();
148 148
const flowId = computed(() => route.query.id);
149
const store = useStore();
150
console.log(store.getters['sceneFlow/curLogicFlowInfo']);
149
// const store = useStore();
150
// console.log(store.getters['sceneFlow/curLogicFlowInfo']);
151 151
152
const curLogicInfo = store.getters['sceneFlow/curLogicFlowInfo'] || null;
152
// const curLogicInfo = store.getters['sceneFlow/curLogicFlowInfo'] || null;
153
const curLogicInfo = JSON.parse(localStorage.getItem('logicDetail'));
153 154
// 表格信息
154 155
const table = ref({
155 156
  modelAttrs: {

+ 2 - 1
src/views/_components/right-panel/PanelSql.vue

@ -230,7 +230,8 @@ if (isSelectSql.value) {
230 230
// sql选择
231 231
function handleChange(val: any) {
232 232
  const selectedItem = sqlList.value.filter((item: any) => item.id === val)[0];
233
  functionData.value.datasource = selectedItem?.databaseCode || '';
233
  // functionData.value.datasource = selectedItem?.databaseCode || '';
234
  functionData.value.datasource = `business_${val || ''}`;
234 235
  functionData.value.sql = selectedItem?.sql || '';
235 236
}
236 237
watch(

+ 3 - 1
src/views/flow/Flow.vue

@ -98,9 +98,11 @@ async function getLogicDetailById() {
98 98
      subFlowDetail.value = res.result;
99 99
      const panelGlobal = {};
100 100
      panelGlobal[flowId.value] = JSON.parse(res.result?.databusData) || {};
101
      const logicDetail = res.result;
101 102
      localStorage.setItem('panelGlobal', JSON.stringify(panelGlobal));
103
      localStorage.setItem('logicDetail', JSON.stringify(logicDetail));
102 104
      store.commit('setBreadData', [
103
        { name: '系统管理', to: { name: 'SystemList' } },
105
        { name: '流程编排', to: { name: 'SystemList' } },
104 106
        {
105 107
          name: subFlowDetail.value.systemName,
106 108
          to: {

+ 4 - 2
src/views/flow/SystemDetail.vue

@ -157,7 +157,7 @@ async function getSystemDetail() {
157 157
      curVersionId.value = systemInfo.value.version.id;
158 158
      versionState.value = systemInfo.value.version.state;
159 159
      store.commit('setBreadData', [
160
        { name: '系统管理', to: { name: 'SystemList' } },
160
        { name: '流程编排', to: { name: 'SystemList' } },
161 161
        { name: systemInfo.value.name }
162 162
      ]);
163 163
    } else {
@ -294,7 +294,9 @@ function getModuleData() {
294 294
      console.log(moduleTreeData.value);
295 295
      console.log(curLogic.value);
296 296
      setTimeout(() => {
297
        logicTree.value.treeRef.setCurrentKey(curLogic.value, true);
297
        if (logicTree.value) {
298
          logicTree.value.treeRef.setCurrentKey(curLogic.value, true);
299
        }
298 300
      }, 100);
299 301
      defaultProps.value['default-expanded-keys'] =
300 302
        moduleTreeData.value.datas?.[0]?.id;

+ 1 - 1
src/views/flow/_components/ApiDetailPage.vue

@ -206,7 +206,7 @@ function logicOperation(state, msg) {
206 206
          if (res.resultCode === '0') {
207 207
            proxy.$message.success(res.resultMsg);
208 208
          } else {
209
            proxy.$message.error(res.resultMsg, 'error');
209
            proxy.$message.error(res.resultMsg);
210 210
          }
211 211
        })
212 212
        .catch((err) => {