const companyList = [
    {value:0,label:'广西'}  ,
    {value:1,label:'广州'}  ,
    {value:2,label:'石家庄'}  ,
];

function getCompanyName(value){
    let arr = companyList.filter(v=>v.value === value);
    let title = '';
    if(arr.length > 0){title = arr[0].label}
    return title;
}

function getCompanyValueArray(){
    let arr = [];
    companyList.map(v=>{
        arr.push(v.value)
    })
    return arr;
}

module.exports = {
    companyList,
    getCompanyName,
    getCompanyValueArray
}
