kz-ui-base 1.0.157 → 1.0.159

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -72,13 +72,13 @@ export default class DatePicker extends Vue {
72
72
  public currentValue = (this as any).value;
73
73
  public type = "date";
74
74
  public placeholder =
75
- (this as any).setting && (this as any).setting.range ? "false" : "选择日期";
75
+ (this as any).setting && (this as any).setting.range ? "false" : (this as any).t('common.selectDate');
76
76
  public rangeSeparator =
77
- (this as any).setting && (this as any).setting.range ? "至" : "-";
77
+ (this as any).setting && (this as any).setting.range ? (this as any).t('common.to') : "-";
78
78
  public startPlaceholder =
79
- (this as any).setting && (this as any).setting.range ? "开始日期" : "";
79
+ (this as any).setting && (this as any).setting.range ? (this as any).t('common.startDate') : "";
80
80
  public endPlaceholder =
81
- (this as any).setting && (this as any).setting.range ? "结束日期" : "";
81
+ (this as any).setting && (this as any).setting.range ? (this as any).t('common.endDate') : "";
82
82
 
83
83
  created() {
84
84
  if (this.value) {
@@ -40,7 +40,7 @@
40
40
  :disabled="disabled ? true : column.disabled ? true : false"
41
41
  :filterable="filterable"
42
42
  :remote="remote"
43
- :placeholder="column.placeholder ? column.placeholder : '请选择'"
43
+ :placeholder="column.placeholder ? column.placeholder : t('common.pleaseSelect')"
44
44
  :remote-method="remoteMethod"
45
45
  :loading="remote ? loading : false"
46
46
  :multiple="multiple"
@@ -66,7 +66,7 @@
66
66
  :options="data"
67
67
  @input="updateValue"
68
68
  :normalizer="normalizer"
69
- placeholder="请选择"
69
+ :placeholder="t('common.pleaseSelect')"
70
70
  />
71
71
  </el-form-item>
72
72
 
@@ -96,7 +96,7 @@
96
96
  <el-input
97
97
  slot="reference"
98
98
  v-model="input"
99
- placeholder="请输入内容"
99
+ :placeholder="t('common.pleaseEnterContent')"
100
100
  @input="inputChange"
101
101
  ></el-input>
102
102
  </el-popover>
@@ -140,7 +140,7 @@
140
140
  :options="data"
141
141
  @input="updateValue"
142
142
  :normalizer="normalizer"
143
- placeholder="请选择"
143
+ :placeholder="t('common.pleaseSelect')"
144
144
  />
145
145
  </el-form-item>
146
146
  </template>
@@ -628,7 +628,7 @@ export default class dropDownList extends Vue {
628
628
  "dictLabel",
629
629
  "dictValue"
630
630
  );
631
- let newitems = [{ text: this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:"---请选择---", value: undefined }];
631
+ let newitems = [{ text: this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:(this as any).t('common.pleaseSelectAll'), value: undefined }];
632
632
  items.forEach((item) => {
633
633
  if (item.text.indexOf(this.setting.findValue) != -1) {
634
634
  newitems.push(item);
@@ -733,7 +733,7 @@ export default class dropDownList extends Vue {
733
733
  this.setting.displayField || "componentName",
734
734
  this.setting.valueField || "id"
735
735
  );
736
- let newitems = [{ text:this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:"---请选择---", value: undefined }];
736
+ let newitems = [{ text:this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:(this as any).t('common.pleaseSelectAll'), value: undefined }];
737
737
  items.forEach((item: any) => {
738
738
  if (item.value) {
739
739
  if (
@@ -836,7 +836,7 @@ export default class dropDownList extends Vue {
836
836
  if (!valueField) valueField = this.setting.valueField;
837
837
  var items = [];
838
838
  if (this.setting.isShowPleaseChoose != false)
839
- items.push({ text:this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:"---请选择---", value: undefined });
839
+ items.push({ text:this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:(this as any).t('common.pleaseSelectAll'), value: undefined });
840
840
  if (source) {
841
841
  this.itemList = source;
842
842
  for (var item of source) {
@@ -845,7 +845,7 @@ export default class dropDownList extends Vue {
845
845
  }
846
846
  /*console.log("下拉",items);*/
847
847
  if (this.column.setting && this.column.setting.chooseFirst) {
848
- if (items[0].text ==this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:"---请选择---" || items[0].text == "请选择") {
848
+ if (items[0].text ==this.setting.allName?this.setting.allName:store.state.permission.allName?store.state.permission.allName:(this as any).t('common.pleaseSelectAll') || items[0].text == (this as any).t('common.pleaseSelect')) {
849
849
  this.$set(this.entity, String(this.column.property), items[1].text);
850
850
  this.onChangeEvent(this.entity[this.column.property], true);
851
851
  } else {
@@ -26,9 +26,9 @@
26
26
  type="primary"
27
27
  :loading="tableSetting.submitLoading"
28
28
  @click="submitForm"
29
- >确 定</el-button
29
+ >{{ t('common.confirm') }}</el-button
30
30
  >
31
- <el-button @click="cancel">取 消</el-button>
31
+ <el-button @click="cancel">{{ t('common.cancel') }}</el-button>
32
32
  </div>
33
33
  </slot>
34
34
  </div>
@@ -59,7 +59,7 @@ export default class lookupDialog extends Vue {
59
59
  // 提交状态
60
60
  submitLoading: false,
61
61
  // 弹出层标题
62
- title: "请选择",
62
+ title: (this as any).t('common.pleaseSelect'),
63
63
  // 保存时是否自动关闭
64
64
  isCloseOnSave: true,
65
65
  // 启用多选模式
@@ -26,7 +26,7 @@
26
26
  size=""
27
27
  :disabled="!currentEntity"
28
28
  @click="print"
29
- >打 印</el-button
29
+ >{{ t('common.print') }}</el-button
30
30
  >
31
31
  <el-button
32
32
  type="primary"
@@ -35,10 +35,10 @@
35
35
  size=""
36
36
  :disabled="!currentEntity"
37
37
  @click="printView"
38
- >打 预 览</el-button
38
+ >{{ t('common.printPreview') }}</el-button
39
39
  >
40
- <el-button @click="cancel">取 消</el-button>
41
- <el-button @click="downloadPrintClient">下载打印插件</el-button>
40
+ <el-button @click="cancel">{{ t('common.cancel') }}</el-button>
41
+ <el-button @click="downloadPrintClient">{{ t('common.downloadPrintClient') }}</el-button>
42
42
  </div>
43
43
  </el-dialog>
44
44
  </template>
@@ -83,7 +83,7 @@ export default class printDialog extends Vue {
83
83
  // 提交状态
84
84
  submitLoading: false,
85
85
  // 弹出层标题
86
- title: "请选择",
86
+ title: (this as any).t('common.pleaseSelect'),
87
87
  // 保存时是否自动关闭
88
88
  isCloseOnSave: true,
89
89
  // 启用多选模式
@@ -114,38 +114,38 @@ export default class printDialog extends Vue {
114
114
  },
115
115
  // 列表列信息
116
116
  listColumns: [
117
- { key: 0, text: `序号`, property: "id", visible: true },
118
- { key: 1, text: `模板编号`, property: "templateNo", visible: true },
119
- { key: 2, text: `模板名称`, property: "templateName", visible: true },
117
+ { key: 0, text: (this as any).t('common.serialNumber'), property: "id", visible: true },
118
+ { key: 1, text: (this as any).t('common.templateNo'), property: "templateNo", visible: true },
119
+ { key: 2, text: (this as any).t('common.templateName'), property: "templateName", visible: true },
120
120
  {
121
121
  key: 3,
122
- text: `模板类型`,
122
+ text: (this as any).t('common.templateType'),
123
123
  property: "templateType",
124
124
  visible: true,
125
125
  setting: { dictType: "sys_template_type" },
126
126
  },
127
127
  {
128
128
  key: 4,
129
- text: `模板内容`,
129
+ text: (this as any).t('common.templateContent'),
130
130
  property: "templateContent",
131
131
  visible: true,
132
132
  },
133
- { key: 5, text: `模板设置`, property: "setting", visible: true },
133
+ { key: 5, text: (this as any).t('common.templateSetting'), property: "setting", visible: true },
134
134
  {
135
135
  key: 6,
136
- text: `模板版本号`,
136
+ text: (this as any).t('common.templateVersion'),
137
137
  property: "templateDescribe",
138
138
  visible: true,
139
139
  },
140
140
  {
141
141
  key: 7,
142
- text: `模板描述`,
142
+ text: (this as any).t('common.templateDescription'),
143
143
  property: "templateDescribe",
144
144
  visible: true,
145
145
  },
146
146
  {
147
147
  key: 8,
148
- text: `状态`,
148
+ text: (this as any).t('common.status'),
149
149
  property: "templateStatus",
150
150
  setting: { dictType: "sys_template_status" },
151
151
  },
@@ -154,7 +154,7 @@ export default class printDialog extends Vue {
154
154
  // 列表查询条件
155
155
  searchRules: [
156
156
  {
157
- text: `模板类型`,
157
+ text: (this as any).t('common.templateType'),
158
158
  property: "templateType",
159
159
  displayType: "DropDownList",
160
160
  setting: { dictType: "sys_template_type" },
@@ -162,12 +162,12 @@ export default class printDialog extends Vue {
162
162
  },
163
163
 
164
164
  // {
165
- // text: `模板类型`,
165
+ // text: (this as any).t('common.templateType'),
166
166
  // property: "templateType",
167
167
  // visible: false,
168
168
  // value: this.templateType,
169
169
  // },
170
- { text: `模板名称`, property: "templateName" },
170
+ { text: (this as any).t('common.templateName'), property: "templateName" },
171
171
  ],
172
172
  //弹框是否显示确定 取消
173
173
  footerButton: true,
@@ -22,9 +22,9 @@
22
22
  type="primary"
23
23
  :loading="setting.submitLoading"
24
24
  @click="submitForm"
25
- >确 定</el-button
25
+ >{{ t('common.confirm') }}</el-button
26
26
  >
27
- <el-button @click="cancel">取 消</el-button>
27
+ <el-button @click="cancel">{{ t('common.cancel') }}</el-button>
28
28
  </div>
29
29
  </div>
30
30
  </template>
@@ -67,7 +67,7 @@ export default {
67
67
  name: "basic",
68
68
  visable: true,
69
69
  icon: "ion-plus-round",
70
- text: "基本信息",
70
+ text: (this as any).t('common.basicInfo'),
71
71
  type: "area",
72
72
  },
73
73
  {
@@ -116,10 +116,10 @@
116
116
  icon="el-icon-search"
117
117
  size="mini"
118
118
  @click="handleQuery"
119
- >搜索</el-button
119
+ >{{ t('common.search') }}</el-button
120
120
  >
121
121
  <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
122
- >重置</el-button
122
+ >{{ t('common.reset') }}</el-button
123
123
  >
124
124
  </el-form-item>
125
125
  </el-form>
@@ -144,7 +144,7 @@
144
144
  <el-table-column
145
145
  v-if="listSetting.isShowIndexColumn == true"
146
146
  type="index"
147
- label="序号"
147
+ :label="t('common.index')"
148
148
  width="50"
149
149
  align="center"
150
150
  >
@@ -250,7 +250,7 @@
250
250
  </template>
251
251
 
252
252
  <el-table-column
253
- label="操作"
253
+ :label="t('common.operation')"
254
254
  align="center"
255
255
  min-width="160"
256
256
  class-name="small-padding fixed-width"
@@ -9,7 +9,7 @@
9
9
  <!-- <el-table-column v-if="listSetting.isShowIndex != false" type="index" prop="index" label="序号" width="50"
10
10
  align="center">
11
11
  </el-table-column> -->
12
- <el-table-column v-if="listSetting.isShowIndexColumn != false" type="index" prop="index" label="序号" width="50"
12
+ <el-table-column v-if="listSetting.isShowIndexColumn != false" type="index" prop="index" :label="t('common.index')" width="50"
13
13
  align="center">
14
14
  <template scope="scope">
15
15
  <span>{{
@@ -202,7 +202,7 @@
202
202
  </el-table-column>
203
203
  </template>
204
204
 
205
- <el-table-column label="操作" align="center" min-width="160" class-name="small-padding fixed-width"
205
+ <el-table-column :label="t('common.operation')" align="center" min-width="160" class-name="small-padding fixed-width"
206
206
  v-if="listSetting.isShowOpColumn">
207
207
  <template slot-scope="scope">
208
208
  <el-button v-for="(opMenu, index) in listCustomOpMenus" :key="index" size="mini" type="text" :icon="opMenu.icon"
@@ -478,7 +478,7 @@ export default class table extends Vue {
478
478
  }
479
479
  /** 自定义列显示格式方法 */
480
480
  remarkFormat(data, column) {
481
- return data.remark ? "有备注" : "无备注";
481
+ return data.remark ? (this as any).t('common.hasRemark') : (this as any).t('common.noRemark');
482
482
  }
483
483
  /** 自定义列点击方法 */
484
484
  onFilePriview(data, column) {
@@ -486,7 +486,7 @@ export default class table extends Vue {
486
486
  }
487
487
  /** 自定义列显示Html */
488
488
  getFilePriviewLink(data, column) {
489
- return `<a href="${getFilePriviewUrl(data.remark)}" target="_blank">${data.remark ? "自定义预览" : ""
489
+ return `<a href="${getFilePriviewUrl(data.remark)}" target="_blank">${data.remark ? (this as any).t('common.customPreview') : ""
490
490
  }</a>`;
491
491
  }
492
492
  //列表点击属性字段点击
@@ -513,7 +513,7 @@ export default class table extends Vue {
513
513
  });
514
514
  columns.forEach((column, index) => {
515
515
  if (index === 0) {
516
- sums[index] = "合计";
516
+ sums[index] = (this as any).t('common.total');
517
517
  return;
518
518
  }
519
519
  if (sumColumns.indexOf(column.property) < 0) {
@@ -27,7 +27,7 @@
27
27
  </el-form-item>
28
28
  <!-- 字数统计显示:仅当 showWordCount 为 true 时显示 -->
29
29
  <div v-if="column.showWordCount" class="word-count">
30
- {{ currentLength }} / {{ column.maxLength || '不限' }}
30
+ {{ currentLength }} / {{ column.maxLength || t('common.noLimit') }}
31
31
  </div>
32
32
  </div>
33
33
  </template>
@@ -74,7 +74,7 @@
74
74
  :options="data"
75
75
  @input="updateValue"
76
76
  :normalizer="normalizer"
77
- placeholder="请选择"
77
+ :placeholder="t('common.pleaseSelect')"
78
78
  />
79
79
  </el-form-item>
80
80
  </template>
@@ -352,7 +352,7 @@ export default class upload extends Vue {
352
352
  }
353
353
  return;
354
354
  }
355
- (this as any).$message.success("上传成功");
355
+ (this as any).$message.success((this as any).t('common.uploadSuccess'));
356
356
  this.fileList.push({
357
357
  name: res.data.materialNick,
358
358
  url: res.data.materialUrl,
@@ -11,7 +11,7 @@
11
11
  :before-upload="handleBeforeUpload" :data="{ folderId: '0' }" :limit="limit" :on-error="handleUploadError"
12
12
  :on-exceed="handleExceed" :on-success="handleUploadSuccess" :headers="headers" :on-progress='handleProgress'
13
13
  ref="upload" :on-remove="handleRemove" multiple :file-list="fileList">
14
- <el-button size="small" type="primary">点击上传</el-button>
14
+ <el-button size="small" type="primary">{{ t('common.clickToUpload') }}</el-button>
15
15
  </el-upload>
16
16
  <el-dialog :visible.sync="dialogVisible">
17
17
  <img width="100%" :src="dialogImageUrl" alt="">
@@ -35,7 +35,7 @@
35
35
  :underline="false"
36
36
  @click="handleDelete(index)"
37
37
  type="danger"
38
- >删除</el-link
38
+ >{{ t('common.delete') }}</el-link
39
39
  >
40
40
  </div>
41
41
  </li>
@@ -205,7 +205,7 @@ export default class upload extends Vue {
205
205
  });
206
206
  if (!isTypeOk) {
207
207
  (this as any).$message.error(
208
- `文件格式不正确, 请上传${this.fileType.join("/")}格式文件!`
208
+ (this as any).t('common.incorrectFileFormat').replace('{fileType}', this.fileType.join("/"))
209
209
  );
210
210
  return false;
211
211
  }
@@ -215,7 +215,7 @@ export default class upload extends Vue {
215
215
  const isLt = file.size / 1024 / 1024 < this.fileSize;
216
216
  if (!isLt) {
217
217
  (this as any).$message.error(
218
- `上传文件大小不能超过 ${this.fileSize} MB!`
218
+ (this as any).t('common.fileSizeExceeded').replace('{fileSize}', this.fileSize)
219
219
  );
220
220
  return false;
221
221
  }
@@ -224,12 +224,12 @@ export default class upload extends Vue {
224
224
  }
225
225
  // 文件个数超出
226
226
  public handleExceed() {
227
- (this as any).$message.error(`上传文件数量不能超过 ${this.limit} 个!`);
227
+ (this as any).$message.error((this as any).t('common.fileCountExceeded').replace('{limit}', this.limit));
228
228
  }
229
229
  // 上传失败
230
230
  public handleUploadError(err) {
231
231
 
232
- (this as any).$message.error("上传失败, 请重试");
232
+ (this as any).$message.error((this as any).t('common.uploadFailed'));
233
233
 
234
234
  }
235
235
  // 上传成功回调
@@ -258,7 +258,7 @@ export default class upload extends Vue {
258
258
  }
259
259
  return
260
260
  }
261
- (this as any).$message.success("上传成功")
261
+ (this as any).$message.success((this as any).t('common.uploadSuccess'))
262
262
  this.fileList.push({
263
263
  name: file.name,
264
264
  url: res.data.materialUrl,
@@ -87,7 +87,7 @@ export default class uploadDialog extends Vue {
87
87
  this.setting.open = false;
88
88
  this.setting.isUploading = false;
89
89
  (this.$refs.setting as any).clearFiles();
90
- (this as any).$alert(response.msg, "导入结果", {
90
+ (this as any).$alert(response.msg, (this as any).t('common.importResult'), {
91
91
  dangerouslyUseHTMLString: true,
92
92
  });
93
93
  this.$emit("onImportSuccess", null);
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <div
3
3
  v-loading="exportButton"
4
- element-loading-text="数据加载中..."
4
+ :element-loading-text="t('common.loading')"
5
5
  :class="{
6
6
  'dialog-body-wrapper': true,
7
7
  }"
@@ -31,7 +31,7 @@
31
31
  icon="el-icon-plus"
32
32
  type="primary"
33
33
  size="mini"
34
- >添加下层</el-button
34
+ >{{ t('common.addSubLevel') }}</el-button
35
35
  >
36
36
  <el-button
37
37
  style="flex: 1"
@@ -40,7 +40,7 @@
40
40
  icon="el-icon-edit"
41
41
  type="success"
42
42
  size="mini"
43
- >修改本层</el-button
43
+ >{{ t('common.editCurrentLevel') }}</el-button
44
44
  >
45
45
  <el-button
46
46
  style="flex: 1"
@@ -49,7 +49,7 @@
49
49
  icon="el-icon-delete"
50
50
  type="danger"
51
51
  size="mini"
52
- >删除本层</el-button
52
+ >{{ t('common.deleteCurrentLevel') }}</el-button
53
53
  >
54
54
  </div>
55
55
  <div
@@ -284,13 +284,13 @@
284
284
  icon="el-icon-search"
285
285
  size="mini"
286
286
  @click="handleQuery"
287
- >{{ this.t('common.search') }}</el-button
287
+ >{{ t('common.search') }}</el-button
288
288
  >
289
289
  <el-button
290
290
  icon="el-icon-refresh"
291
291
  size="mini"
292
292
  @click="resetQuery"
293
- >{{ this.t('common.reset') }}</el-button
293
+ >{{ t('common.reset') }}</el-button
294
294
  >
295
295
  <AdvancedQueryClose
296
296
  style="
@@ -312,7 +312,7 @@
312
312
 
313
313
  <div
314
314
  v-loading="contentLoading"
315
- element-loading-text="数据加载中..."
315
+ :element-loading-text="t('common.loading')"
316
316
  class="content-container"
317
317
  >
318
318
  <div
@@ -380,7 +380,7 @@
380
380
  >
381
381
  <el-dropdown>
382
382
  <el-button type="info" size="mini">
383
- 审批<i class="el-icon-arrow-down el-icon--right"></i>
383
+ {{ t('common.approve') }}<i class="el-icon-arrow-down el-icon--right"></i>
384
384
  </el-button>
385
385
  <el-dropdown-menu slot="dropdown">
386
386
  <template v-for="(opMenu, index) in opMenus">
@@ -468,7 +468,7 @@
468
468
  :height="tableHeight"
469
469
  :border="true"
470
470
  v-loading="loading"
471
- element-loading-text="数据加载中..."
471
+ :element-loading-text="t('common.loading')"
472
472
  :data="listData"
473
473
  :show-summary="listSetting.isShowSumRow"
474
474
  :summary-method="getSummaries"
@@ -599,10 +599,10 @@
599
599
  "
600
600
  >
601
601
  {{
602
- String(scope.row[column.property]) === "1" ? "是" : ""
602
+ String(scope.row[column.property]) === "1" ? t('common.yes') : ""
603
603
  }}
604
604
  {{
605
- String(scope.row[column.property]) === "0" ? "否" : ""
605
+ String(scope.row[column.property]) === "0" ? t('common.no') : ""
606
606
  }}
607
607
  </span>
608
608
  <el-tag
@@ -864,7 +864,7 @@
864
864
  </template>
865
865
 
866
866
  <el-table-column
867
- label="操作"
867
+ :label="t('common.operation')"
868
868
  align="center"
869
869
  min-width="160"
870
870
  class-name="small-padding fixed-width"
@@ -911,7 +911,7 @@
911
911
  :height="tableHeight"
912
912
  :border="true"
913
913
  v-loading="loading"
914
- element-loading-text="数据加载中..."
914
+ :element-loading-text="t('common.loading')"
915
915
  :data="dataForTables[index]"
916
916
  :show-summary="listSetting.isShowSumRow"
917
917
  :summary-method="getSummaries"
@@ -996,12 +996,12 @@
996
996
  >
997
997
  {{
998
998
  String(scope.row[column.property]) === "1"
999
- ? "是"
999
+ ? t('common.yes')
1000
1000
  : ""
1001
1001
  }}
1002
1002
  {{
1003
1003
  String(scope.row[column.property]) === "0"
1004
- ? "否"
1004
+ ? t('common.no')
1005
1005
  : ""
1006
1006
  }}
1007
1007
  </span>
@@ -1147,7 +1147,7 @@
1147
1147
  </template>
1148
1148
 
1149
1149
  <el-table-column
1150
- label="操作"
1150
+ :label="t('common.operation')"
1151
1151
  align="center"
1152
1152
  min-width="160"
1153
1153
  class-name="small-padding fixed-width"
@@ -1190,8 +1190,8 @@
1190
1190
  </el-col>
1191
1191
  </el-row>
1192
1192
  <div v-if="value && value.btnShow" class="dialog-footer">
1193
- <el-button type="primary" @click="submitForm">确 定</el-button>
1194
- <el-button @click="cancel">取 消</el-button>
1193
+ <el-button type="primary" @click="submitForm">{{ t('common.confirm') }}</el-button>
1194
+ <el-button @click="cancel">{{ t('common.cancel') }}</el-button>
1195
1195
  </div>
1196
1196
 
1197
1197
  <!-- 添加或修改参数配置对话框 -->
@@ -1701,7 +1701,7 @@ export default class listBasePage extends Vue {
1701
1701
  name: "basic",
1702
1702
  visable: true,
1703
1703
  icon: "ion-plus-round",
1704
- text: '基本信息',
1704
+ text: (this as any).t('common.basicInfo'),
1705
1705
  type: "area",
1706
1706
  },
1707
1707
  ];
@@ -1746,7 +1746,7 @@ export default class listBasePage extends Vue {
1746
1746
  // 是否显示编辑窗口
1747
1747
  isShow: false,
1748
1748
  // 弹出层标题(用户导入)
1749
- title: '打印模版',
1749
+ title: (this as any).t('common.printTemplate'),
1750
1750
  //打印类型
1751
1751
  templateType: "",
1752
1752
  // 保存时是否自动关闭
@@ -1883,7 +1883,7 @@ export default class listBasePage extends Vue {
1883
1883
  initField(this.moduleName, data)
1884
1884
  .then((response) => {
1885
1885
  if ((response as any).code != 200) {
1886
- (this as any).msgError("初始化失败!");
1886
+ (this as any).msgError((this as any).t('common.initFailed'));
1887
1887
  }
1888
1888
  listEntity(
1889
1889
  this.moduleName,
@@ -2038,7 +2038,7 @@ export default class listBasePage extends Vue {
2038
2038
  }
2039
2039
  /** 自定义列显示格式方法 */
2040
2040
  remarkFormat(data, column) {
2041
- return data.remark ? "有备注" : "无备注";
2041
+ return data.remark ? (this as any).t('common.hasRemark') : (this as any).t('common.noRemark');
2042
2042
  }
2043
2043
  /** 自定义列点击方法 */
2044
2044
  onFilePriview(data, column) {
@@ -2047,7 +2047,7 @@ export default class listBasePage extends Vue {
2047
2047
  /** 自定义列显示Html */
2048
2048
  getFilePriviewLink(data, column) {
2049
2049
  return `<a href="${this.getFilePriviewUrl(data.remark)}" target="_blank">${
2050
- data.remark ? "自定义预览" : ""
2050
+ data.remark ? (this as any).t('common.customPreview') : ""
2051
2051
  }</a>`;
2052
2052
  }
2053
2053
  getSummaries(param) {
@@ -2055,7 +2055,7 @@ export default class listBasePage extends Vue {
2055
2055
  const sums = [];
2056
2056
  columns.forEach((column, index) => {
2057
2057
  if (index === 0) {
2058
- sums[index] = '合计';
2058
+ sums[index] = (this as any).t('common.total');
2059
2059
  return;
2060
2060
  }
2061
2061
  const values = data.map((item) => Number(item[column.property]));
@@ -2540,7 +2540,7 @@ export default class listBasePage extends Vue {
2540
2540
  var setting = JSON.parse(args.data.setting);
2541
2541
  }
2542
2542
  } catch (ex) {
2543
- (self as any).msgError("验证规则设置有误,JSON格式不正确,请检查!");
2543
+ (self as any).msgError((self as any).t('common.validationRulesJsonError'));
2544
2544
  this.$set(this.editSetting, "submitLoading", false);
2545
2545
  return;
2546
2546
  }
@@ -2579,7 +2579,7 @@ export default class listBasePage extends Vue {
2579
2579
  updateEntity(self.moduleName, self.serviceName, args.data).then(
2580
2580
  (response) => {
2581
2581
  self.getList();
2582
- (self as any).msgSuccess("修改成功");
2582
+ (self as any).msgSuccess((self as any).t('common.updateSuccess'));
2583
2583
  if (self.editSetting.isCloseOnSave) self.editSetting.isShow = false;
2584
2584
  self.$set(this.editSetting, "submitLoading", false);
2585
2585
  //self.editSetting.isShow = false;
@@ -2620,7 +2620,7 @@ export default class listBasePage extends Vue {
2620
2620
  addEntity(self.moduleName, self.serviceName, args.data).then(
2621
2621
  (response) => {
2622
2622
  self.getList();
2623
- (self as any).msgSuccess("新增成功");
2623
+ (self as any).msgSuccess((self as any).t('common.addSuccess'));
2624
2624
  if (self.editSetting.isCloseOnSave) self.editSetting.isShow = false;
2625
2625
  self.$set(this.editSetting, "submitLoading", false);
2626
2626
  },
@@ -2784,7 +2784,7 @@ export default class listBasePage extends Vue {
2784
2784
  this.serviceName == "search")
2785
2785
  ) {
2786
2786
  if (this.currentSelectTreeId == undefined) {
2787
- (this as any).msgError("请在左侧选择一个界面设置!");
2787
+ (this as any).msgError((this as any).t('common.pleaseSelectInterfaceSetting'));
2788
2788
  } else {
2789
2789
  Vue.set(
2790
2790
  this.currentEntity,
@@ -2792,7 +2792,7 @@ export default class listBasePage extends Vue {
2792
2792
  this.currentSelectTreeId
2793
2793
  );
2794
2794
  this.editSetting.isShow = true;
2795
- this.editSetting.title = "添加";
2795
+ this.editSetting.title = (this as any).t('common.add');
2796
2796
  }
2797
2797
  } else {
2798
2798
  this.editColumns.forEach((item) => {
@@ -2801,7 +2801,7 @@ export default class listBasePage extends Vue {
2801
2801
  }
2802
2802
  });
2803
2803
  this.editSetting.isShow = true;
2804
- this.editSetting.title = "添加";
2804
+ this.editSetting.title = (this as any).t('common.add');
2805
2805
  }
2806
2806
  }
2807
2807
  /** 复制按钮操作 */
@@ -2828,9 +2828,9 @@ export default class listBasePage extends Vue {
2828
2828
  }
2829
2829
  }
2830
2830
  });
2831
- self.editSetting.title = "修改";
2831
+ self.editSetting.title = (self as any).t('common.edit');
2832
2832
  if (row == "detail") {
2833
- self.editSetting.title = "查看";
2833
+ self.editSetting.title = (self as any).t('common.view');
2834
2834
  this.oldeditColumns = [];
2835
2835
  this.oldeditColumns = JSON.parse(JSON.stringify(this.editColumns));
2836
2836
  this.oldeditColumns.forEach((item) => {
@@ -2863,9 +2863,9 @@ export default class listBasePage extends Vue {
2863
2863
  const text = this.idsText;
2864
2864
  let $this = this;
2865
2865
  (this as any)
2866
- .$confirm("是否确认删除?", "警告", {
2867
- confirmButtonText: "确定",
2868
- cancelButtonText: "取消",
2866
+ .$confirm((this as any).t('common.confirmDelete'), (this as any).t('common.warning'), {
2867
+ confirmButtonText: (this as any).t('common.confirm'),
2868
+ cancelButtonText: (this as any).t('common.cancel'),
2869
2869
  type: "warning",
2870
2870
  })
2871
2871
  .then(function () {
@@ -2877,7 +2877,7 @@ export default class listBasePage extends Vue {
2877
2877
  })
2878
2878
  .then(() => {
2879
2879
  $this.getList();
2880
- ($this as any).msgSuccess("删除成功");
2880
+ ($this as any).msgSuccess(($this as any).t('common.deleteSuccess'));
2881
2881
  });
2882
2882
 
2883
2883
  this.submitLoading = false;
@@ -2885,7 +2885,7 @@ export default class listBasePage extends Vue {
2885
2885
  /** 导出按钮操作 */
2886
2886
  handleExport() {
2887
2887
  if (this.exportButton) {
2888
- (this as any).msgError("请勿重复点击");
2888
+ (this as any).msgError((this as any).t('common.doNotClickRepeatedly'));
2889
2889
  return;
2890
2890
  }
2891
2891
  this.exportButton = true;
@@ -2909,7 +2909,7 @@ export default class listBasePage extends Vue {
2909
2909
  }
2910
2910
  /** 导入按钮操作 */
2911
2911
  handleImport() {
2912
- this.uploadSetting.title = "导入";
2912
+ this.uploadSetting.title = (this as any).t('common.import');
2913
2913
  // 上传的地址
2914
2914
  this.uploadSetting.url =
2915
2915
  process.env.VUE_APP_BASE_API +
@@ -2933,7 +2933,7 @@ export default class listBasePage extends Vue {
2933
2933
  this.getList();
2934
2934
  }
2935
2935
  handlePrint() {
2936
- this.printSetting.title = "打印模板";
2936
+ this.printSetting.title = (this as any).t('common.printTemplate');
2937
2937
  this.printSetting.currentEntity = this.currentEntity;
2938
2938
  this.printSetting.templateType = `/${this.moduleName}/${this.serviceName}`;
2939
2939
  (this.$refs.printDialog as any).show();
@@ -3083,9 +3083,9 @@ export default class listBasePage extends Vue {
3083
3083
  };
3084
3084
 
3085
3085
  (this as any)
3086
- .$prompt("请输入审批流标题(可为空)", "是否确认发起审批?", {
3087
- confirmButtonText: "确定",
3088
- cancelButtonText: "取消",
3086
+ .$prompt((this as any).t('common.pleaseEnterWorkflowTitle'), (this as any).t('common.confirmStartApproval'), {
3087
+ confirmButtonText: (this as any).t('common.confirm'),
3088
+ cancelButtonText: (this as any).t('common.cancel'),
3089
3089
  //inputPattern: /[\w!#$%&'*+/=?^_`{|}~-]+(?:\.[\w!#$%&'*+/=?^_`{|}~-]+)*@(?:[\w](?:[\w-]*[\w])?\.)+[\w](?:[\w-]*[\w])?/,
3090
3090
  // inputErrorMessage: '邮箱格式不正确'
3091
3091
  })
@@ -3096,7 +3096,7 @@ export default class listBasePage extends Vue {
3096
3096
  startWorkflow(this.moduleName, this.serviceName, params, this.wfKey)
3097
3097
  .then((response) => {
3098
3098
  (this as any).exportButton = false;
3099
- (this as any).$message.success("发起审批成功");
3099
+ (this as any).$message.success((this as any).t('common.startApprovalSuccess'));
3100
3100
  (this as any).getList();
3101
3101
  })
3102
3102
  .catch((e) => {
@@ -3119,7 +3119,7 @@ export default class listBasePage extends Vue {
3119
3119
  component: WfDialog,
3120
3120
  setting: {
3121
3121
  isShow: true,
3122
- title: "审批进度",
3122
+ title: (this as any).t('common.approvalProgress'),
3123
3123
  size: "full", //可选项tiny/small/large/full
3124
3124
  // height: "80vh",
3125
3125
  labelWidth: "120px", //input标题宽度 不传默认为100px
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kz-ui-base",
3
- "version": "1.0.157",
3
+ "version": "1.0.159",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {