diff --git a/src/api/model/am.js b/src/api/model/am.js
new file mode 100644
index 00000000..54414d7d
--- /dev/null
+++ b/src/api/model/am.js
@@ -0,0 +1,44 @@
+import config from "@/config"
+import http from "@/utils/request"
+/*区域接口*/
+export default {
+
+ area: {
+ list: {
+ name: "获取",
+ req: async function(data){
+ return await http.get(
+ `${config.API_URL}/am/area/`,
+ data
+ );
+ }
+ },
+ update: {
+ name: "更新",
+ req: async function(id, data){
+ return await http.put(
+ `${config.API_URL}/am/area/${id}/`,
+ data);
+ }
+ },
+ create: {
+ name: "创建",
+ req: async function(data){
+ return await http.post(
+ `${config.API_URL}/am/area/`,
+ data);
+ }
+ },
+ delete: {
+ name: "删除",
+ req: async function(id){
+ return await http.delete(
+ `${config.API_URL}/am/area/${id}/`);
+ }
+ }
+ },
+
+
+
+
+}
\ No newline at end of file
diff --git a/src/api/model/opm.js b/src/api/model/opm.js
new file mode 100644
index 00000000..11b9b336
--- /dev/null
+++ b/src/api/model/opm.js
@@ -0,0 +1,78 @@
+import config from "@/config"
+import http from "@/utils/request"
+/*作业接口*/
+export default {
+ /*作业许可证分类*/
+ oplcate: {
+ list: {
+ name: "获取",
+ req: async function(data){
+ return await http.get(
+ `${config.API_URL}/opm/opl_cate/`,
+ data
+ );
+ }
+ },
+ update: {
+ name: "更新",
+ req: async function(id, data){
+ return await http.put(
+ `${config.API_URL}/opm/opl_cate/${id}/`,
+ data);
+ }
+ },
+ create: {
+ name: "创建",
+ req: async function(data){
+ return await http.post(
+ `${config.API_URL}/opm/opl_cate/`,
+ data);
+ }
+ },
+ delete: {
+ name: "删除",
+ req: async function(id){
+ return await http.delete(
+ `${config.API_URL}/opm/opl_cate/${id}/`);
+ }
+ }
+ },
+
+
+
+ /*作业*/
+ operation: {
+ list: {
+ name: "获取",
+ req: async function(data){
+ return await http.get(
+ `${config.API_URL}/opm/operation/`,
+ data
+ );
+ }
+ },
+ update: {
+ name: "更新",
+ req: async function(id, data){
+ return await http.put(
+ `${config.API_URL}/opm/operation/${id}/`,
+ data);
+ }
+ },
+ create: {
+ name: "创建",
+ req: async function(data){
+ return await http.post(
+ `${config.API_URL}/opm/operation/`,
+ data);
+ }
+ },
+ delete: {
+ name: "删除",
+ req: async function(id){
+ return await http.delete(
+ `${config.API_URL}/opm/operation/${id}/`);
+ }
+ }
+ },
+}
\ No newline at end of file
diff --git a/src/api/model/system.js b/src/api/model/system.js
index 4237d33c..b8eff89a 100644
--- a/src/api/model/system.js
+++ b/src/api/model/system.js
@@ -319,7 +319,7 @@ export default {
},
runOnce: {
name: "执行一次",
- req: async function(data){
+ req: async function(data,id){
return await http.post(`${config.API_URL}/system/ptask/${id}/run_once/`,data);
}
},
diff --git a/src/api/model/wf.js b/src/api/model/wf.js
index a96f3b8f..1619c315 100644
--- a/src/api/model/wf.js
+++ b/src/api/model/wf.js
@@ -74,7 +74,7 @@ export default {
ticketItem: {
name: "工单详情",
req: async function(id){
- return await http.get(`${config.API_URL}/wf/ticket/${id}/`);
+ return await http.get(`${config.API_URL}/wf/ticket/${id}/`);
}
},
create: {
diff --git a/src/components/scTable/index.vue b/src/components/scTable/index.vue
index 5c50b401..2b59c252 100644
--- a/src/components/scTable/index.vue
+++ b/src/components/scTable/index.vue
@@ -264,7 +264,7 @@ export default {
},
//获取数据
async getData() {
- debugger;
+
this.loading = true;
var reqData = {
[config.request.page]: this.currentPage,
@@ -278,7 +278,7 @@ export default {
// delete reqData[config.request.pageSize]
}
Object.assign(reqData, this.tableParams);
- debugger;
+
try {
var res = await this.apiObj.req(reqData);
if (this.hidePagination) {
@@ -288,7 +288,7 @@ export default {
}
if(this.$route.path==='/sys/dept'||this.$route.path==='/sys/perm'){
this.tableData = this.redata(res);
- debugger;
+
console.log(this.tableData)
}else{
this.tableData = res || [];
@@ -316,7 +316,7 @@ export default {
}
if(this.$route.path==='/sys/dept'||this.$route.path==='/ops/menu'){
this.tableData = this.redata(dataList);
- debugger;
+
console.log(this.tableData)
}else{
this.tableData = dataList || [];
@@ -354,7 +354,7 @@ export default {
parent.children = parent.children ? parent.children : [];
parent.children.push(item);
}
- debugger;
+
console.log(arr);
return arr;
},
diff --git a/src/config/route.js b/src/config/route.js
index 58161793..6f92c82f 100644
--- a/src/config/route.js
+++ b/src/config/route.js
@@ -153,6 +153,15 @@ const routes = [
},
"component": "opm/operation"
},
+ {
+ "name": "oplcate",
+ "path": "/opm/oplcate",
+ "meta": {
+ "title": "许可证分类",
+ "icon": "el-icon-menu",
+ },
+ "component": "opm/oplcate"
+ },
]
},
{
diff --git a/src/utils/verificate.js b/src/utils/verificate.js
index 36b7983e..51c97443 100644
--- a/src/utils/verificate.js
+++ b/src/utils/verificate.js
@@ -16,3 +16,30 @@ export function verifyCars(rule, value, callback) {
}
callback()
}
+export function genTree(data) {
+ const result = []
+ if (!Array.isArray(data)) {
+ return result
+ }
+ data.forEach(item => {
+ delete item.children
+ })
+ const map = {}
+ data.forEach(item => {
+ item.label = item.name
+ if(item.fullname){
+ item.label = item.fullname
+ }
+ item.value = item.id
+ map[item.id] = item
+ })
+ data.forEach(item => {
+ const parent = map[item.parent]
+ if (parent) {
+ (parent.children || (parent.children = [])).push(item)
+ } else {
+ result.push(item)
+ }
+ })
+ return result
+ }
diff --git a/src/views/hrm/ep_form.vue b/src/views/hrm/ep_form.vue
index 5fdb0a1d..231630b9 100644
--- a/src/views/hrm/ep_form.vue
+++ b/src/views/hrm/ep_form.vue
@@ -356,15 +356,15 @@
},
//表单提交方法
submit() {
- debugger;
+ //debugger;
this.$refs.dialogForm.validate((valid) => {
- debugger;
+ // debugger;
if (valid) {
- debugger;
+ // debugger;
this.isSaveing = true;
this.addForm.dept = this.addForm.dept[1];
if (this.mode === 'add') {
- debugger;
+ // debugger;
this.$API.hrm.employee.create.req(this.form)
.then(res => {
this.isSaveing = false;
@@ -406,7 +406,7 @@
},
//表单注入数据
setData(data) {
- debugger;
+ //debugger;
console.log(defaultForm);
// this.form = defaultForm;
Object.assign(this.form, data);
diff --git a/src/views/opm/operation.vue b/src/views/opm/operation.vue
index e69de29b..b5a9bb6e 100644
--- a/src/views/opm/operation.vue
+++ b/src/views/opm/operation.vue
@@ -0,0 +1,162 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 查看
+ 编辑
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/opm/operation_form.vue b/src/views/opm/operation_form.vue
new file mode 100644
index 00000000..9e5c7e88
--- /dev/null
+++ b/src/views/opm/operation_form.vue
@@ -0,0 +1,254 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 保存
+ 取消
+
+
+
+
+
+
+
+
diff --git a/src/views/opm/oplcate.vue b/src/views/opm/oplcate.vue
new file mode 100644
index 00000000..24da7283
--- /dev/null
+++ b/src/views/opm/oplcate.vue
@@ -0,0 +1,162 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 查看
+ 编辑
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/opm/oplcate_form.vue b/src/views/opm/oplcate_form.vue
new file mode 100644
index 00000000..e60d9027
--- /dev/null
+++ b/src/views/opm/oplcate_form.vue
@@ -0,0 +1,228 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 保存
+ 取消
+
+
+
+
+
+
+
+
diff --git a/src/views/ops/logInfo.vue b/src/views/ops/logInfo.vue
index eca96198..16997aa7 100644
--- a/src/views/ops/logInfo.vue
+++ b/src/views/ops/logInfo.vue
@@ -32,7 +32,7 @@
methods: {
setData(data){
this.data = data;
- debugger;
+ // debugger;
console.log(data);
let dataStr = '';
for (let i in data) {
diff --git a/src/views/ops/menu.vue b/src/views/ops/menu.vue
index 126b7241..0dde3998 100644
--- a/src/views/ops/menu.vue
+++ b/src/views/ops/menu.vue
@@ -148,14 +148,14 @@
},
handleChange(value) {
// this.menu.checked = check.checkedKeys;
- debugger;
+ // debugger;
console.log(value);
console.log(this.addForm.parent);
},
//加载树数据
async getGroup() {
var res = await this.$API.system.permission.list.req({page: 0});
- debugger;
+ // debugger;
let permList = res;
this.permList = res;
let posts = [];
@@ -177,7 +177,7 @@
parent.children = parent.children ? parent.children : [];
parent.children.push(item);
}
- debugger;
+ //debugger;
this.group = arr;
},
@@ -190,7 +190,7 @@
this.codesLimited = true;
},
saveCodes(){
- debugger;console.log(this.addForm.codes);
+ // debugger;console.log(this.addForm.codes);
this.addForm.codes.push(this.codes);
this.codes = ''
},
@@ -204,7 +204,7 @@
this.type = 'edit';
this.addForm.id = row.id;
this.addForm.name = row.name;
- debugger;
+ // debugger;
console.log(row.codes);
this.codes = row.codes.join(',');
let parent = row.parent!==null?this.findParents(this.permList, row.parent):'';
@@ -217,7 +217,7 @@
this.limitedVisible = true;
},
findParents(arr, parent) {
- debugger;
+ //debugger;
let data = [];
arr.forEach(item => {
if (item.id === parent) {
@@ -229,7 +229,7 @@
}
}
});
- debugger;
+ //debugger;
return data
},
//删除
@@ -262,7 +262,7 @@
this.addForm.codes.push(this.codes)
}
this.$refs.addForm.validate((valid) => {
- debugger;
+ // debugger;
if (valid) {
this.isSaveing = true;
var res;
diff --git a/src/views/sys/dept.vue b/src/views/sys/dept.vue
index f7b347f0..19be4468 100644
--- a/src/views/sys/dept.vue
+++ b/src/views/sys/dept.vue
@@ -123,7 +123,7 @@
methods: {
handleChange(value) {
// this.menu.checked = check.checkedKeys;
- debugger;
+ //debugger;
console.log(value);
console.log(this.addForm.parent);
},
@@ -165,7 +165,7 @@
},
//编辑
editDept(row){
- debugger;
+ // debugger;
this.temp = [];
this.type='edit';
this.addForm.id=row.id;
@@ -205,7 +205,7 @@
let that = this;
this.addForm.parent = this.addForm.parent!==null?this.addForm.parent[0]?this.addForm.parent[0]:'':'';
this.$refs.addForm.validate( (valid) => {
- debugger;
+ // debugger;
if (valid) {
this.isSaveing = true;
var res;
diff --git a/src/views/sys/dict.vue b/src/views/sys/dict.vue
index ca286e40..8e274972 100644
--- a/src/views/sys/dict.vue
+++ b/src/views/sys/dict.vue
@@ -41,6 +41,7 @@
+
@@ -90,7 +91,7 @@
-
+
@@ -275,7 +276,7 @@
},
findParents(arr,parent){
let that = this;
- debugger;
+ // debugger;
arr.forEach(item=>{
debugger;
if(item.id===parent){
@@ -314,7 +315,7 @@
}
}*/
let res = this.$API.system.dicttype.delete.req(data.id);
- debugger;
+ // debugger;
console.log(res);
this.getDicType();
this.showDicloading = false;
diff --git a/src/views/sys/role.vue b/src/views/sys/role.vue
index 8d4cd0c8..ab46c33a 100644
--- a/src/views/sys/role.vue
+++ b/src/views/sys/role.vue
@@ -120,7 +120,7 @@
methods: {
handleChange(item, check) {
this.menu.checked = check.checkedKeys;
- debugger;
+ //debugger;
console.log(check);
console.log(this.checkList);
},
@@ -142,7 +142,7 @@
// debugger;
console.log(obj);
for (let item of posts) {
- debugger;
+ // debugger;
if (item.parentId == null) {
arr.push(item);
continue
diff --git a/src/views/sys/task.vue b/src/views/sys/task.vue
index de41d813..46fde2b4 100644
--- a/src/views/sys/task.vue
+++ b/src/views/sys/task.vue
@@ -198,6 +198,7 @@
},
run(task){
this.$API.system.task.runOnce.req(task.id).then(res=>{
+ console.log(res)
})
this.$message.success(`已成功执行计划任务:${task.title}`)
}
diff --git a/src/views/sys/user.vue b/src/views/sys/user.vue
index 085cf96d..7608d9bb 100644
--- a/src/views/sys/user.vue
+++ b/src/views/sys/user.vue
@@ -248,7 +248,7 @@
},
//编辑
formEdit(row,index) {
- debugger;
+ // debugger;
console.log(row);
this.limitedVisible = true;
if(index==='1'){
@@ -339,7 +339,7 @@
//树点击事件
groupClick(data) {
console.log(data);
- debugger;
+ // debugger;
let params = {belong_dept: data.id};
this.$refs.table.reload(params);
},
@@ -349,7 +349,7 @@
},
//表单提交方法
submit(){
- debugger;
+ // debugger;
this.$refs.addForm.validate(async (valid) => {
if (valid) {
this.isSaveing = true;