|
djun
发表于 2017-10-14 22:40
来自 韩国
- function generateSerial(permanent) {
- if(permanent == "Select model")
- return "Please select a model first!";
- return (random(11,14) + "30" + permanent + "n" + padLeft(random(1,030000),6)).toUpperCase();
- }
- function padLeft(nr, n) {
- return Array(n - String(nr).length + 1).join('0') + nr;
- }
复制代码 |
|