智慧保安APP验收版本
shuishen
2021-12-02 56ee0734fc0cbca40f992823a636ec8feebd1f80
1
2
3
4
5
6
7
8
9
10
function random(min, max) {
    if (min >= 0 && max > 0 && max >= min) {
        let gab = max - min + 1;
        return Math.floor(Math.random() * gab + min);
    } else {
        return 0;
    }
}
 
export default random;