import { n as e } from "./chunk-TYymryXo.mjs";
import { Fragment as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createTextVNode as a, createVNode as o, defineComponent as s, openBlock as c, ref as l, useModel as u, withCtx as d } from "vue";
import { Form as f, FormItem as p, Input as m, Radio as h, RadioGroup as g } from "ant-design-vue/es";
//#region src/pages/flow-create/flow-model/createComponents/step2.vue?vue&type=script&setup=true&lang.ts
var _ = /* @__PURE__ */ s({
	name: "CreateStep2",
	__name: "step2",
	props: {
		modelValue: {},
		modelModifiers: {}
	},
	emits: ["update:modelValue"],
	setup(e, { expose: s }) {
		let _ = l(), v = u(e, "modelValue"), y = {
			formType: [{
				required: !0,
				message: "表单类型不能为空",
				trigger: "blur"
			}],
			formCustomCreatePath: [{
				required: !0,
				message: "表单提交路由不能为空",
				trigger: "blur"
			}],
			formCustomViewPath: [{
				required: !0,
				message: "表单查看地址不能为空",
				trigger: "blur"
			}]
		};
		function b() {
			return _.value.validate();
		}
		return s({ validateForm: b }), (e, s) => {
			let l = h, u = g, b = p, x = m, S = f;
			return c(), n(S, {
				ref_key: "formRef",
				ref: _,
				model: v.value,
				rules: y,
				"label-col": { style: "width:120px" }
			}, {
				default: d(() => [o(b, {
					label: "表单类型",
					name: "formType"
				}, {
					default: d(() => [o(u, {
						value: v.value.formType,
						"onUpdate:value": s[0] ||= (e) => v.value.formType = e,
						disabled: ""
					}, {
						default: d(() => [o(l, { value: 10 }, {
							default: d(() => [...s[3] ||= [a(" 流程表单 ", -1)]]),
							_: 1
						}), o(l, { value: 20 }, {
							default: d(() => [...s[4] ||= [a(" 业务表单 ", -1)]]),
							_: 1
						})]),
						_: 1
					}, 8, ["value"])]),
					_: 1
				}), v.value.formType === 20 ? (c(), i(t, { key: 0 }, [o(b, {
					label: "表单提交路由",
					name: "formCustomCreatePath"
				}, {
					default: d(() => [o(x, {
						value: v.value.formCustomCreatePath,
						"onUpdate:value": s[1] ||= (e) => v.value.formCustomCreatePath = e,
						maxlength: 30,
						placeholder: "请输入表单提交路由"
					}, null, 8, ["value"])]),
					_: 1
				}), o(b, {
					label: "表单查看路由",
					name: "formCustomViewPath"
				}, {
					default: d(() => [o(x, {
						value: v.value.formCustomViewPath,
						"onUpdate:value": s[2] ||= (e) => v.value.formCustomViewPath = e,
						maxlength: 30,
						placeholder: "请输入表单查看路由"
					}, null, 8, ["value"])]),
					_: 1
				})], 64)) : r("", !0)]),
				_: 1
			}, 8, ["model"]);
		};
	}
}), v = /* @__PURE__ */ e({ default: () => y }), y = _;
//#endregion
export { v as n, y as t };
