Selaa lähdekoodia

feat(report): 添加i18n配置及优化DailyReport表单

whj 1 kuukausi sitten
vanhempi
commit
c7c2783bc5

+ 8 - 0
.vscode/settings.json

@@ -0,0 +1,8 @@
+{
+  "i18n-ally.localesPaths": [
+    "src/i18n",
+    "public/ueditor/lang",
+    "public/utf8-jsp/lang",
+    "src/assets/static/ueditor/lang"
+  ]
+}

+ 1 - 1
src/views/report/daily/DailyReport.vue

@@ -585,7 +585,7 @@ export default {
       }
     },
     handleEdit (record) {
-      // this.$refs.baseForm.base(record)
+      this.$refs.baseForm.base(record)
     },
     handleOk (record) {
       updateProduceReport(record).then((res) => {

+ 3 - 3
src/views/report/daily/modules/BaseForm.vue

@@ -6,7 +6,7 @@
         保存
       </a-button>
     </template>
-    <a-input @keydown.enter="save" style="width:100%" v-model="record[key]"></a-input>
+    <a-input @keydown.enter="save" style="width:100%" v-model="record[key]" :addonAfter=" this.record.unit"></a-input>
   </a-modal>
 </template>
 
@@ -39,11 +39,11 @@ export default {
   },
   created () {},
   methods: {
-    base (record, key) {
+    base (record, key = 'value') {
       this.visible = true
       this.key = key
       console.log(record)
-      this.title = record.date + this.titleMap[key]
+      this.title = record.date + '(' + record.lineOne + record.name + ')'
       this.record = {
         ...record
       }