From 85291f4dd87bd2f0e647530bf5986c089a7ecf93 Mon Sep 17 00:00:00 2001
From: long <18782126717@163.com>
Date: Fri, 21 Oct 2022 17:58:48 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=99=BB=E5=BD=95=E8=BE=93?=
=?UTF-8?q?=E5=85=A5=E6=A1=86=E5=86=85=E5=AE=B9=EF=BC=8C=E4=BF=AE=E6=94=B9?=
=?UTF-8?q?=E9=A2=84=E7=AE=97=E8=AE=A1=E5=88=92=E6=B5=81=E7=A8=8B?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.env.production | 2 +-
package.json | 2 +-
.../form/ProcessMaterialWarehousingForm.vue | 175 +++++++--------
.../activiti/form/ProcessUdgetPlanForm.vue | 200 +++++++++---------
src/views/user/Login.vue | 4 +-
5 files changed, 197 insertions(+), 186 deletions(-)
diff --git a/.env.production b/.env.production
index 18c6447..54499d6 100644
--- a/.env.production
+++ b/.env.production
@@ -1,4 +1,4 @@
NODE_ENV=production
-VUE_APP_API_BASE_URL=https://bootapi.jeecg.com
+VUE_APP_API_BASE_URL=http://haoyi.scyp.ink/prod-api
VUE_APP_CAS_BASE_URL=http://localhost:8888/cas
VUE_APP_ONLINE_BASE_URL=http://fileview.jeecg.com/onlinePreview
\ No newline at end of file
diff --git a/package.json b/package.json
index 689fda5..5bf19f8 100644
--- a/package.json
+++ b/package.json
@@ -6,7 +6,7 @@
"pre": "cnpm install || yarn --registry https://registry.npm.taobao.org || npm install --registry https://registry.npm.taobao.org ",
"serve": "vue-cli-service serve",
"build:test": "vue-cli-service build --mode test",
- "build": "vue-cli-service build",
+ "build": "vue-cli-service build --mode production",
"lint": "vue-cli-service lint"
},
"dependencies": {
diff --git a/src/views/activiti/form/ProcessMaterialWarehousingForm.vue b/src/views/activiti/form/ProcessMaterialWarehousingForm.vue
index 2bd8076..5f7afcf 100644
--- a/src/views/activiti/form/ProcessMaterialWarehousingForm.vue
+++ b/src/views/activiti/form/ProcessMaterialWarehousingForm.vue
@@ -31,7 +31,8 @@
-
+
@@ -135,92 +136,92 @@ import JSelectCompany from '../../../components/jeecgbiz/JSelectCompany'
loading: false,
dataSource: [],
columns: [
- {
- title: '物料组',
- key: 'materialGroup',
- type: FormTypes.sel_search,
- dictCode:"",
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '物料号',
- key: 'materialNumber',
- type: FormTypes.sel_search,
- dictCode:"",
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '物料描述',
- key: 'materialDescription',
- type: FormTypes.input,
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '仓储地点_id',
- key: 'unitWasteWarehouseCodeId',
- type: FormTypes.sel_search,
- dictCode:"",
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '生产时间',
- key: 'productionTime',
- type: FormTypes.date,
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '保质期',
- key: 'expirationDate',
- type: FormTypes.date,
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '是否到货',
- key: 'arrivalNotice',
- type: FormTypes.select,
- dictCode:"",
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '入库时间',
- key: 'storageTime',
- type: FormTypes.date,
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '入库人',
- key: 'librarySign',
- type: FormTypes.sel_search,
- dictCode:"",
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
- {
- title: '核算属性',
- key: 'materialType',
- type: FormTypes.sel_search,
- dictCode:"",
- width:"200px",
- placeholder: '请输入${title}',
- defaultValue:'',
- },
+ // {
+ // title: '物料组',
+ // key: 'materialGroup',
+ // type: FormTypes.sel_search,
+ // dictCode:"",
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '物料号',
+ // key: 'materialNumber',
+ // type: FormTypes.sel_search,
+ // dictCode:"",
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '物料描述',
+ // key: 'materialDescription',
+ // type: FormTypes.input,
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '仓储地点_id',
+ // key: 'unitWasteWarehouseCodeId',
+ // type: FormTypes.sel_search,
+ // dictCode:"",
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '生产时间',
+ // key: 'productionTime',
+ // type: FormTypes.date,
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '保质期',
+ // key: 'expirationDate',
+ // type: FormTypes.date,
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '是否到货',
+ // key: 'arrivalNotice',
+ // type: FormTypes.select,
+ // dictCode:"",
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '入库时间',
+ // key: 'storageTime',
+ // type: FormTypes.date,
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '入库人',
+ // key: 'librarySign',
+ // type: FormTypes.sel_search,
+ // dictCode:"",
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
+ // {
+ // title: '核算属性',
+ // key: 'materialType',
+ // type: FormTypes.sel_search,
+ // dictCode:"",
+ // width:"200px",
+ // placeholder: '请输入${title}',
+ // defaultValue:'',
+ // },
{
title: '器材编号',
key: 'equipment',
diff --git a/src/views/activiti/form/ProcessUdgetPlanForm.vue b/src/views/activiti/form/ProcessUdgetPlanForm.vue
index c4a67bb..6a70725 100644
--- a/src/views/activiti/form/ProcessUdgetPlanForm.vue
+++ b/src/views/activiti/form/ProcessUdgetPlanForm.vue
@@ -5,6 +5,11 @@
+
+
+
+
+
@@ -89,7 +94,7 @@
const VALIDATE_NO_PASSED = Symbol()
import pick from 'lodash.pick'
- import { getAction } from '@/api/manage'
+ import { getAction,httpAction } from '@/api/manage'
import { FormTypes, getRefPromise,validateFormAndTables } from '@/utils/JEditableTableUtil'
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
import JFormContainer from '@/components/jeecg/JFormContainer'
@@ -158,70 +163,70 @@
placeholder: '请输入${title}',
defaultValue: ''
},
- {
- title: '物料描述',
- key: 'materialDescription',
- type: FormTypes.input,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '仓储地点_id',
- key: 'unitWasteWarehouseCodeId',
- type: FormTypes.input,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '生产时间',
- key: 'productionTime',
- type: FormTypes.date,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '保质期',
- key: 'expirationDate',
- type: FormTypes.date,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '是否到货',
- key: 'arrivalNotice',
- type: FormTypes.inputNumber,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '入库时间',
- key: 'storageTime',
- type: FormTypes.date,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '入库人',
- key: 'librarySign',
- type: FormTypes.input,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
- {
- title: '核算属性',
- key: 'materialType',
- type: FormTypes.input,
- width: '200px',
- placeholder: '请输入${title}',
- defaultValue: ''
- },
+ // {
+ // title: '物料描述',
+ // key: 'materialDescription',
+ // type: FormTypes.input,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '仓储地点_id',
+ // key: 'unitWasteWarehouseCodeId',
+ // type: FormTypes.input,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '生产时间',
+ // key: 'productionTime',
+ // type: FormTypes.date,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '保质期',
+ // key: 'expirationDate',
+ // type: FormTypes.date,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '是否到货',
+ // key: 'arrivalNotice',
+ // type: FormTypes.inputNumber,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '入库时间',
+ // key: 'storageTime',
+ // type: FormTypes.date,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '入库人',
+ // key: 'librarySign',
+ // type: FormTypes.input,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
+ // {
+ // title: '核算属性',
+ // key: 'materialType',
+ // type: FormTypes.input,
+ // width: '200px',
+ // placeholder: '请输入${title}',
+ // defaultValue: ''
+ // },
{
title: '物料名称及规格型号',
key: 'materialName',
@@ -385,8 +390,13 @@
this.data = formData;
console.log("表单回显数据",this.data)
this.$nextTick(() => {
- this.form.setFieldsValue(pick(this.data,'company', 'createTime', 'sysOrgCode', 'createBy', 'materialType', 'processPlan', 'needTime', 'orderNumber', 'fileId'))
+ this.form.setFieldsValue(pick(this.data,'id','company', 'createTime', 'sysOrgCode', 'createBy', 'materialType', 'processPlan', 'needTime', 'orderNumber', 'fileId'))
});
+ // 加载子表数据
+ if (this.data.id) {
+ let params = { id: this.data.id }
+ this.requestSubTableData(this.url.processUdgetPlanMaterial.list, params, this.processUdgetPlanMaterialTable)
+ }
this.btndisabled = false;
}else {
this.$message.error(res.message)
@@ -465,35 +475,35 @@
throw this.throwNotFunction('classifyIntoFormData')
}
let formData = this.classifyIntoFormData(allValues)
- console.log('格式化后的数据',formData)
- // this.form.validateFields((err, values) => {
- // if (!err) {
- // let formData = Object.assign(this.data||{}, values)
- // formData.procDefId = this.processData.id;
- // formData.procDeTitle = this.processData.name;
- // if (!formData.tableName)formData.tableName = this.processData.businessTable;
- // formData.filedNames = _.keys(values).join(",");
- // console.log('formData', values)
- // this.processUdgetPlanMaterialTable.dataSource=[]
- // console.log('子表数据')
- // var url = this.url.add;
- // if (!this.isNew){
- // url = this.url.edit;
- // }
- // //this.btndisabled = true;
- // // this.postFormAction(url,formData).then((res)=>{
- // // if (res.success){
- // // this.$message.success("保存成功!")
- // // //todo 将表单的数据传给父组件
- // // this.$emit('afterSubmit',formData)
- // // }else {
- // // this.$message.error(res.message)
- // // }
- // // }).finally(()=>{
- // // this.btndisabled = false;
- // // })
- // }
- // })
+
+ this.form.validateFields((err, values) => {
+ if (!err) {
+ formData.procDefId = this.processData.id;
+ formData.procDeTitle = this.processData.name;
+ formData.title=this.processData.description;
+ if (!formData.tableName)formData.tableName = this.processData.businessTable;
+ console.log('格式化后的数据',formData)
+ var url = this.url.add;
+ let method='post';
+ if (!this.isNew){
+ url = this.url.edit;
+ method='put';
+ }
+ console.log('提交方法',method)
+ this.btndisabled = true;
+ httpAction(url,formData,method).then((res)=>{
+ if (res.success){
+ this.$message.success("保存成功!")
+ //todo 将表单的数据传给父组件
+ this.$emit('afterSubmit',formData)
+ }else {
+ this.$message.error(res.message)
+ }
+ }).finally(()=>{
+ this.btndisabled = false;
+ })
+ }
+ })
})
},
diff --git a/src/views/user/Login.vue b/src/views/user/Login.vue
index 18bbbe5..07e78d1 100644
--- a/src/views/user/Login.vue
+++ b/src/views/user/Login.vue
@@ -11,7 +11,7 @@
size="large"
v-decorator="['username',validatorRules.username,{ validator: this.handleUsernameOrEmail }]"
type="text"
- placeholder="请输入帐户名 / admin">
+ placeholder="请输入帐户名">
@@ -22,7 +22,7 @@
size="large"
type="password"
autocomplete="false"
- placeholder="密码 / 123456">
+ placeholder="请输入密码">