diff --git a/src/components/Template/BaseInfoFormPcakge.vue b/src/components/Template/BaseInfoFormPcakge.vue
index 7a362cf..d140ebc 100644
--- a/src/components/Template/BaseInfoFormPcakge.vue
+++ b/src/components/Template/BaseInfoFormPcakge.vue
@@ -94,7 +94,7 @@
{{ formFields[sItem.subKey] }}
- {{ formFields[sItem.subKey] }}
+ {{ formFields[sItem.subKey] }}
{{ formFields[sItem.subKey] }}
-
{{ formFields[sItem.subKey] }}
+
{{ formFields[sItem.subKey] }}
@@ -157,12 +157,19 @@ export default {
}
}
},
-
mounted() {
this.handleFormField();
},
methods: {
+ getFillType(type) {
+ const typeObj = {
+ actFill: "orange-border",//实际填写的边框颜色
+ green: "green-border",
+ preFill: "blue-border",//预填写的边框颜色
+ }
+ return typeObj[type] || ""
+ },
onInputNumberChange(key, val){
if(val === 0){
this.formFields[key] = null;
@@ -413,4 +420,25 @@ export default {
width: auto;
margin-left: 10px;
}
+.clickable{
+ cursor: pointer;
+ width: auto;
+ margin-left: 10px;
+ min-width: 100px;
+ height: 28px;
+ border-radius: 4px;
+ border:1px solid #4ea2ff;
+}
+
+.orange-border {
+ border-color: #f9c588;
+}
+
+.green-border {
+ border-color: green;
+}
+
+.blue-border {
+ border-color: #4ea2ff;
+}
\ No newline at end of file
diff --git a/src/components/Template/DecimalInput.vue b/src/components/Template/DecimalInput.vue
new file mode 100644
index 0000000..0fe677c
--- /dev/null
+++ b/src/components/Template/DecimalInput.vue
@@ -0,0 +1,146 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/src/components/Template/HandleFormItem.vue b/src/components/Template/HandleFormItem.vue
index 9f14ea8..4d409fe 100644
--- a/src/components/Template/HandleFormItem.vue
+++ b/src/components/Template/HandleFormItem.vue
@@ -1,73 +1,54 @@
-
+
-
-
-
-
+
+
+
-
-
+
+
diff --git a/src/views/business/comps/template/mixins/templateMixin.js b/src/views/business/comps/template/mixins/templateMixin.js
index 77b6906..18228a4 100644
--- a/src/views/business/comps/template/mixins/templateMixin.js
+++ b/src/views/business/comps/template/mixins/templateMixin.js
@@ -50,6 +50,16 @@ export default {
setConditionOptions(options) {
this.$store.commit('template/SET_CONDITION_OPTIONS', options)
},
+ //统一处理blur事件,因为有效周期和过期日期是相关的,所以需要在有效周期失焦时更新过期日期
+ onHandleBlur(fields){
+ const {key ,effectivePeriodUnit,effectivePeriod} = fields;
+ const {createTime} = this.formData;
+ if(key ==="effectivePeriod"){//统一处理有效周期失焦,计算失效事件,保证字段名不能变
+ const start = moment(createTime);
+ const end = start.add(Number(effectivePeriod), effectivePeriodUnit).format("YYYY-MM-DD HH:mm:ss");
+ this.$refs.stepFormPackageRef.updateFormField("expireDate", end);
+ }
+ }
},
diff --git a/vue.config.js b/vue.config.js
index 054942f..489b432 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -34,8 +34,8 @@ module.exports = {
proxy: {
// detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: {
- target: `http://localhost:8080`,
- //target: `http://39.99.251.173:8080`,
+ // target: `http://localhost:8080`,
+ target: `http://39.99.251.173:8080`,
changeOrigin: true,
pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: ''