"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const fsExtra = require("fs-extra");
const VueParse_1 = require("../../../generator/VueParse");
const path = require("path");
const config_1 = require("../../../../config");
const Common_1 = require("../../Common");
class SaveButton extends Common_1.default {
    constructor(type) {
        super();
        this.name = 'SaveButton';
        this.type = type;
        this.init();
    }
    init() {
        const fileStr = fsExtra.readFileSync(path.join(config_1.default.templatePath, 'component/BaseForm/SaveButton', 'comp.vue'), 'utf8');
        this.vueParse = new VueParse_1.default(this.uuid, fileStr);
    }
    fragment() {
        return `
      <el-button type="primary"  @click="submitForm('form')" style="margin-right: 10px;">
        保存
      </el-button>
    `;
    }
}
exports.default = SaveButton;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2FkYXB0ZXItdnVlL21vZHVsZXMvY3VzdG9tL0Jhc2VGb3JtL1NhdmVCdXR0b24vaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxvQ0FBb0M7QUFDcEMsMERBQW1EO0FBQ25ELDZCQUE2QjtBQUM3QiwrQ0FBd0M7QUFDeEMseUNBQWtDO0FBR2xDLE1BQXFCLFVBQVcsU0FBUSxnQkFBTTtJQU01QyxZQUFhLElBQVk7UUFDdkIsS0FBSyxFQUFFLENBQUE7UUFOVCxTQUFJLEdBQVcsWUFBWSxDQUFDO1FBTzFCLElBQUksQ0FBQyxJQUFJLEdBQUcsSUFBSSxDQUFDO1FBQ2pCLElBQUksQ0FBQyxJQUFJLEVBQUUsQ0FBQztJQUNkLENBQUM7SUFFTyxJQUFJO1FBQ1YsTUFBTSxPQUFPLEdBQUcsT0FBTyxDQUFDLFlBQVksQ0FBQyxJQUFJLENBQUMsSUFBSSxDQUFDLGdCQUFNLENBQUMsWUFBWSxFQUFFLCtCQUErQixFQUFHLFVBQVUsQ0FBQyxFQUFFLE1BQU0sQ0FBQyxDQUFDO1FBQzNILElBQUksQ0FBQyxRQUFRLEdBQUcsSUFBSSxrQkFBUSxDQUFDLElBQUksQ0FBQyxJQUFJLEVBQUUsT0FBTyxDQUFDLENBQUM7SUFDbkQsQ0FBQztJQUVNLFFBQVE7UUFDYixPQUFPOzs7O0tBSU4sQ0FBQztJQUNKLENBQUM7Q0FDRjtBQXhCRCw2QkF3QkMifQ==