|
@@ -95,8 +95,10 @@ const colorList = {
|
|
|
|
|
|
const changeStaff = value => {
|
|
|
const find = props.data.find(i => i.code === value);
|
|
|
- props.modelValue[props.name[0]] = find[props.keys[0]];
|
|
|
- props.modelValue[props.name[1]] = find[props.keys[1]];
|
|
|
+ if (find) {
|
|
|
+ props.modelValue[props.name[0]] = find[props.keys[0]];
|
|
|
+ props.modelValue[props.name[1]] = find[props.keys[1]];
|
|
|
+ }
|
|
|
emit("change", find);
|
|
|
};
|
|
|
|