mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-17 06:46:46 +08:00
专业力必修提交
This commit is contained in:
@@ -11,7 +11,6 @@
|
||||
placeholder="请选择岗位"
|
||||
:options="options"
|
||||
@change="onSelectChange"
|
||||
@search="handleSearch"
|
||||
allowClear
|
||||
showArrow
|
||||
showSearch
|
||||
@@ -20,7 +19,7 @@
|
||||
|
||||
<script>
|
||||
import { ref, watch } from 'vue';
|
||||
import { getAllPosition } from "@/api/growthpath"
|
||||
import { getStdPosition } from "@/api/growthpath"
|
||||
export default {
|
||||
name: 'PostSelect',
|
||||
props: {
|
||||
@@ -45,12 +44,12 @@ export default {
|
||||
|
||||
async function fetchOptions() {
|
||||
try {
|
||||
const data = await getAllPosition({positionName: ''})
|
||||
const data = await getStdPosition({positionName: ''})
|
||||
options.value = data.data.data.map((item) => {
|
||||
return {
|
||||
id: item.positionId,
|
||||
label: item.positionName,
|
||||
value: item.positionName,
|
||||
id: item.stdPosition,
|
||||
label: item.stdPositionName,
|
||||
value: item.stdPosition,
|
||||
};
|
||||
})
|
||||
} catch (error) {
|
||||
@@ -67,17 +66,11 @@ export default {
|
||||
function onSelectChange(newVal,postList ) {
|
||||
emit('update:value', newVal);
|
||||
emit('update:postList', postList);
|
||||
console.log(newVal,postList,'aaaaaa')
|
||||
}
|
||||
async function handleSearch(val){
|
||||
console.log(val,'val')
|
||||
|
||||
}
|
||||
return {
|
||||
selectedValue,
|
||||
options,
|
||||
onSelectChange,
|
||||
handleSearch,
|
||||
};
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user