浏览代码

城市管理

vera_min 3 年之前
父节点
当前提交
16ecc6c6c3
共有 2 个文件被更改,包括 2 次插入8 次删除
  1. 1 1
      src/api/system/index.ts
  2. 1 7
      src/views/system/city/index.vue

+ 1 - 1
src/api/system/index.ts

@@ -130,7 +130,7 @@ export default {
   },
   city: {
     getList: (params: object) => get('/common/city/tree', params),
-    add: (data: object) => post('/common/city/tree', data),
+    add: (data: object) => post('/common/city/add', data),
     edit: (data: object) => put('/common/city/edit', data),
     del: (id: number) => del('/common/city/del', { id }),
     detail: (id: number) => get('/common/city/getInfoById', { id }),

+ 1 - 7
src/views/system/city/index.vue

@@ -28,12 +28,6 @@
               </el-icon>
               新增
             </el-button>
-            <!-- <el-button size="default" type="danger" class="ml10" @click="onRowDel(null)">
-              <el-icon>
-                <ele-Delete />
-              </el-icon>
-              删除
-            </el-button> -->
           </el-form-item>
         </el-form>
       </div>
@@ -162,7 +156,7 @@ export default defineComponent({
 				type: 'warning',
 			})
 				.then(() => {
-					api.heatStation.del(row.id).then(() => {
+					api.city.del(row.id).then(() => {
 						ElMessage.success('删除成功');
 						queryList();
 					});