sign_in.sh 565 字节
#! /bin/bash

echo "批量打卡"

# 待打卡的用户IC卡号列表
icList=("18860189991" "18860189992")
# 设备编号
device_coe='STX-D-0001'
# 测试环境服务地址
host="http://allied-creation-manufacture-test.fjmaimaimai.com/zkteco/iclock/cdata?SN=$device_coe"
# 本地环境服务地址
#host="http://106.75.231.90:9999/zkteco/iclock/cdata?SN=$device_coe"

sign_time=`date "+%Y-%m-%d %H:%M:%S"`

for str in ${icList[*]};do
  echo "IC: $str 打卡时间: $sign_time \r\n"
  curl --location --request POST $host \
  --data-raw "$str	$sign_time	$	YY"
done