//tag规则 release-v188.16.*
//商标工作台未抓取官文提醒
const TaskBase = require("../../task.base");
const system = require("../../../system");
var settings = require("../../../../config/settings");
class TmOfficialTask extends TaskBase {
    constructor() {
        super(TaskBase.getServiceName(TmOfficialTask));
        this.restclient = system.getObject("util.restClient");
    }
    /**
     * 每天9点检查一次
     * @param {*} taskName
     */
    formatedTaskName (taskName) {
        console.log("formatedTaskName", taskName)
        return taskName + "|i|5"
    }
    async subDoTask () {
        console.log("--------------");
        console.log("TestTask1.....");
        var obj = {
        }
        try {
            var url = settings.tmnotifyUrl() + "/api/action/tmNotify/officialCount";
            this.restclient.execPost(obj, url);
            var hburl = settings.tmnotifyhbUrl() + "/api/action/tmNotify/officialCount";
            this.restclient.execPost(obj, hburl);
            return system.getResultSuccess();
        } catch (error) {
            console.log(error);
            return null;
        }
    }
}
module.exports = TmOfficialTask;
