李志伟 преди 3 години
родител
ревизия
b6932efe96
променени са 4 файла, в които са добавени 4 реда и са изтрити 4 реда
  1. 2
    2
      config/routes.js
  2. 1
    1
      src/pages/Machinery/Machinery/Edit/index.jsx
  3. 0
    0
      src/pages/Machinery/Machinery/Edit/style.less
  4. 1
    1
      src/pages/Machinery/Machinery/index.jsx

+ 2
- 2
config/routes.js Целия файл

@@ -119,9 +119,9 @@ export default [
119 119
         component: './Machinery/Machinery',
120 120
       },
121 121
       {
122
-        path: '/Machinery/Machinery/edit.jsx',
122
+        path: '/Machinery/Machinery/Edit',
123 123
         name: '农机编辑',
124
-        component: './Machinery/Machinery/edit.jsx',
124
+        component: './Machinery/Machinery/Edit',
125 125
         hideInMenu: true,
126 126
       },
127 127
       {

src/pages/Machinery/Machinery/edit.jsx → src/pages/Machinery/Machinery/Edit/index.jsx Целия файл

@@ -58,7 +58,7 @@ export default (props) => {
58 58
         .then((res) => {
59 59
           setLoading(false);
60 60
           message.success('数据保存成功');
61
-          history.replace(`./edit.jsx?id=${res.machineryId}`)
61
+          history.replace(`./Edit?id=${res.machineryId}`)
62 62
         })
63 63
         .catch((err) => {
64 64
           setLoading(false);

src/pages/Machinery/Machinery/style.less → src/pages/Machinery/Machinery/Edit/style.less Целия файл


+ 1
- 1
src/pages/Machinery/Machinery/index.jsx Целия файл

@@ -17,7 +17,7 @@ export default (props) => {
17 17
 
18 18
   const gotoEdit = (id) => {
19 19
     const queryStr = id ? `?id=${id}` : '';
20
-    history.push(`./machinery/edit.jsx${queryStr}`);
20
+    history.push(`./machinery/Edit${queryStr}`);
21 21
   };
22 22
   const handleDelete = (id) => {
23 23
     deleteMachinery(id).then(() => {