<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
    xmlns="http://www.jee-soft.cn/bpm/plugins/userCalc/groupRel"
    targetNamespace="http://www.jee-soft.cn/bpm/plugins/userCalc/groupRel"
    xmlns:base="http://www.jee-soft.cn/bpm/plugins/userCalc/base" elementFormDefault="qualified">
    <xs:import namespace="http://www.jee-soft.cn/bpm/plugins/userCalc/base"
        schemaLocation="base.xsd"/>
    <xs:element name="groupRel">
        <xs:annotation>
            <xs:documentation>组和用户关系</xs:documentation>
        </xs:annotation>
        <xs:complexType>
            <xs:complexContent>
                <xs:extension base="base:abstractLogic">
                    <xs:all maxOccurs="1" minOccurs="0">
                        <xs:element name="var" type="base:executorVar" minOccurs="0"/>
                        <xs:element name="groups" minOccurs="0">
                            <xs:annotation>
                                <xs:documentation>指定用户组</xs:documentation>
                            </xs:annotation>
                            <xs:complexType>
                                <xs:attribute name="groupKey" use="required">
                                    <xs:annotation>
                                        <xs:documentation>用户组键</xs:documentation>
                                    </xs:annotation>
                                </xs:attribute>
                                <xs:attribute name="groupName" use="required">
                                    <xs:annotation>
                                        <xs:documentation>用户组名称</xs:documentation>
                                    </xs:annotation>
                                </xs:attribute>
                            </xs:complexType>
                        </xs:element>

                    </xs:all>
                    <xs:attribute name="groupType" use="required">
                        <xs:annotation>
                            <xs:documentation>组类型</xs:documentation>
                        </xs:annotation>
                    </xs:attribute>
                    <xs:attribute name="groupTypeName">
                        <xs:annotation>
                            <xs:documentation>组类型名字</xs:documentation>
                        </xs:annotation>
                    </xs:attribute>
                    <xs:attribute name="source" type="source" use="required">
                        <xs:annotation>
                            <xs:documentation>来源分类</xs:documentation>
                        </xs:annotation>
                    </xs:attribute>
                </xs:extension>
            </xs:complexContent>
        </xs:complexType>
    </xs:element>
    <xs:simpleType name="source">
        <xs:annotation>
            <xs:documentation>人员类型来源</xs:documentation>
        </xs:annotation>
        <xs:restriction base="xs:string">
            <xs:enumeration value="start">
                <xs:annotation>
                    <xs:documentation>发起人</xs:documentation>
                </xs:annotation>
            </xs:enumeration>
            <xs:enumeration value="prev">
                <xs:annotation>
                    <xs:documentation>上一步执行人</xs:documentation>
                </xs:annotation>
            </xs:enumeration>
            <xs:enumeration value="var">
                <xs:annotation>
                    <xs:documentation>变量</xs:documentation>
                </xs:annotation>
            </xs:enumeration>
            <xs:enumeration value="spec">
                <xs:annotation>
                    <xs:documentation>指定用户组</xs:documentation>
                </xs:annotation>
            </xs:enumeration>
        </xs:restriction>
    </xs:simpleType>
</xs:schema>
