@ebiz/designer-components 0.1.8 → 0.1.10

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ebiz/designer-components",
3
- "version": "0.1.8",
3
+ "version": "0.1.10",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -13,11 +13,11 @@
13
13
  <t-icon name="close" class="item-remove" @click="removeItem(index, item.id)"></t-icon>
14
14
  </div>
15
15
  </div>
16
- <t-button @click="showDialog" variant="text" theme="primary">选择人员</t-button>
16
+ <t-button @click="showDialog" variant="text" theme="primary">{{ props.content }}</t-button>
17
17
  </div>
18
18
 
19
19
  <!-- 选择弹窗 -->
20
- <t-dialog v-model:visible="dialogVisible" header="选择人员" :width="800" footer :close-btn="true"
20
+ <t-dialog v-model:visible="dialogVisible" :header="props.content" :width="800" footer :close-btn="true"
21
21
  :close-on-esc-keydown="true" :close-on-overlay-click="true" destroyOnClose>
22
22
 
23
23
  <!-- 选项卡 -->
@@ -221,11 +221,15 @@ const props = defineProps({
221
221
  maxCount: {
222
222
  type: Number,
223
223
  default: 0
224
+ },
225
+ content: {
226
+ type: String,
227
+ default: '选择人员'
224
228
  }
225
229
  });
226
230
 
227
231
  // 定义组件事件
228
- const emit = defineEmits(['update:modelValue', 'change', 'update:visible']);
232
+ const emit = defineEmits(['update:modelValue', 'change', 'update:visible', 'confirm']);
229
233
  const tempVisible = ref(false);
230
234
  // 内部状态变量
231
235
  const dialogVisible = computed({
@@ -690,6 +694,7 @@ const handleConfirm = () => {
690
694
 
691
695
  emit('update:modelValue', selectedEmployeeIds);
692
696
  emit('change', selectedEmployeeIds);
697
+ emit('confirm', selectedEmployeeIds);
693
698
  dialogVisible.value = false;
694
699
  };
695
700