code.svg
17.9 KB
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="processonSvg1000" viewBox="153.0 99.0 873.0 1236.0" width="873.0" height="1236.0"><defs id="ProcessOnDefs1001"><marker id="ProcessOnMarker1028" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1029" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1037" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1038" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1046" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1047" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1075" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1076" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1079" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1080" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1085" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1086" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1089" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1090" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker><marker id="ProcessOnMarker1093" markerUnits="userSpaceOnUse" orient="auto" markerWidth="16.23606797749979" markerHeight="10.550836550532098" viewBox="-1.0 -1.3763819204711736 16.23606797749979 10.550836550532098" refX="-1.0" refY="3.8990363547948754"><path id="ProcessOnPath1094" d="M12.0 3.8990363547948754L0.0 7.798072709589751V0.0Z" stroke="#323232" stroke-width="2.0" fill="#323232" transform="matrix(1.0,0.0,0.0,1.0,0.0,0.0)"/></marker></defs><g id="ProcessOnG1002"><path id="ProcessOnPath1003" d="M153.0 99.0H1026.0V1335.0H153.0V99.0Z" fill="none"/><g id="ProcessOnG1004"><g id="ProcessOnG1005" transform="matrix(1.0,0.0,0.0,1.0,173.0,230.0)" opacity="1.0"><path id="ProcessOnPath1006" d="M0.0 0.0L141.0 0.0L141.0 70.0L0.0 70.0Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1007" transform="matrix(1.0,0.0,0.0,1.0,10.0,18.75)"><text id="ProcessOnText1008" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="60.5" y="13.325">入口文件</text><text id="ProcessOnText1009" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="60.5" y="29.575">/www/index.php</text></g></g><g id="ProcessOnG1010" transform="matrix(1.0,0.0,0.0,1.0,368.0,212.5)" opacity="1.0"><path id="ProcessOnPath1011" d="M20.0 0.0L0.0 0.0L0.0 119.5L20.0 119.5" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="none"/><path id="ProcessOnPath1012" d="M0.0 0.0L638.0 0.0L638.0 119.5L0.0 119.5Z" stroke="#323232" stroke-width="0.0" stroke-dasharray="none" opacity="1.0" fill="none"/><g id="ProcessOnG1013" transform="matrix(1.0,0.0,0.0,1.0,10.0,11.0)"><text id="ProcessOnText1014" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="13.325">1. 自 URL 中分析当前企业目录名(企业域名:QY_DOMAIN)、应用名(唯一标识名:APP_IDENTIFIER</text><text id="ProcessOnText1015" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="29.575">)、应用目录名(APP_DIR,标准产品的APP_IDENTIFIER原则上同APP_DIR是一致的,如果需要重新定义</text><text id="ProcessOnText1016" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="45.825">,可以在应用目录根目录建立app.php <?php $identifier = array('identifier'=>'xxx'); 来自行定义)</text><text id="ProcessOnText1017" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="62.075">2. 重构预定义的环境变量,主要是路径信息,如:PATH_INFO、REQUEST_URI、PHP_SELF</text><text id="ProcessOnText1018" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="78.325">3. 为方便使用,新增了路径信息的预定义环境变量,在原来的变量名加了前缀:CY_。比如:CY_PATH_INF</text><text id="ProcessOnText1019" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="94.575">O、CY_REQUEST_URI、CY_PHP_SELF</text></g></g><g id="ProcessOnG1020" transform="matrix(1.0,0.0,0.0,1.0,173.0,405.0)" opacity="1.0"><path id="ProcessOnPath1021" d="M0.0 0.0L597.0 0.0L597.0 69.0L0.0 69.0Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1022" transform="matrix(1.0,0.0,0.0,1.0,10.0,10.125)"><text id="ProcessOnText1023" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="288.5" y="13.325">根据当前的URL,来获取具体的应用代码目录(APP_DIR),定位到具体的项目应用目录</text><text id="ProcessOnText1024" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="288.5" y="29.575">APP_PATH</text><text id="ProcessOnText1025" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="288.5" y="45.825"></text></g></g><g id="ProcessOnG1026"><path id="ProcessOnPath1027" d="M243.5 300.0L243.5 352.5L471.5 352.5L471.5 389.7639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" fill="none" marker-end="url(#ProcessOnMarker1028)"/></g><g id="ProcessOnG1030" transform="matrix(1.0,0.0,0.0,1.0,173.0,533.0)" opacity="1.0"><path id="ProcessOnPath1031" d="M0.0 0.0L597.0 0.0L597.0 63.0L0.0 63.0Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1032" transform="matrix(1.0,0.0,0.0,1.0,10.0,15.25)"><text id="ProcessOnText1033" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="288.5" y="13.325">进入 ThinkPHP 的框架入口(ThinkPHP.php)</text><text id="ProcessOnText1034" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="288.5" y="29.575">以下的流程均按 ThinkPHP3 的系统流程来走</text></g></g><g id="ProcessOnG1035"><path id="ProcessOnPath1036" d="M471.5 474.0L471.5 503.5L471.5 503.5L471.5 517.7639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" fill="none" marker-end="url(#ProcessOnMarker1037)"/></g><g id="ProcessOnG1039" transform="matrix(1.0,0.0,0.0,1.0,173.0,119.0)" opacity="1.0"><path id="ProcessOnPath1040" d="M0.0 36.5L373.0 0.0L373.0 73.0L0.0 73.0L0.0 36.5Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1041" transform="matrix(1.0,0.0,0.0,1.0,0.0,23.900000000000002)"><text id="ProcessOnText1042" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="186.5" y="13.325">请请求的URL。</text><text id="ProcessOnText1043" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="186.5" y="29.575">WEB SERVER配置 REWRITE</text></g></g><g id="ProcessOnG1044"><path id="ProcessOnPath1045" d="M359.5 192.0L359.5 211.0L243.5 211.0L243.5 214.7639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" fill="none" marker-end="url(#ProcessOnMarker1046)"/></g><g id="ProcessOnG1048" transform="matrix(1.0,0.0,0.0,1.0,173.0,1020.0)" opacity="1.0"><path id="ProcessOnPath1049" d="M20.0 0.0L0.0 0.0L0.0 132.0L20.0 132.0" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="none"/><path id="ProcessOnPath1050" d="M0.0 0.0L784.0 0.0L784.0 132.0L0.0 132.0Z" stroke="#323232" stroke-width="0.0" stroke-dasharray="none" opacity="1.0" fill="none"/><g id="ProcessOnG1051" transform="matrix(1.0,0.0,0.0,1.0,10.0,9.125)"><text id="ProcessOnText1052" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="13.325">团队开发约定:</text><text id="ProcessOnText1053" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="29.575">1. 应用代码使用 PSR-2 风格编码</text><text id="ProcessOnText1054" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="45.825">2. 禁止使用 ThinkPHP 的单字母函数D()、M()导入类库,使用 PHP5 的 use 导入</text><text id="ProcessOnText1055" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="62.075">3. 所有涉及 URI 路径的均不可以直接拼写,改由统一的函数来输出</text><text id="ProcessOnText1056" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="78.325">4. 非必要的情况下,禁止修改框架代码,如果必须要修改的,必须在文档标注</text><text id="ProcessOnText1057" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="94.575">5. 代码注释使用 PHPDoc 规范</text><text id="ProcessOnText1058" fill="#ff3333" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="110.825"></text></g></g><g id="ProcessOnG1059" transform="matrix(1.0,0.0,0.0,1.0,293.25,704.5)" opacity="1.0"><path id="ProcessOnPath1060" d="M0.0 0.0L356.5 0.0L356.5 42.5L0.0 42.5Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1061" transform="matrix(1.0,0.0,0.0,1.0,10.0,13.125)"><text id="ProcessOnText1062" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="168.25" y="13.325">应用的 [APP]/Common/Conf/config.php读取数据库</text></g></g><g id="ProcessOnG1063" transform="matrix(1.0,0.0,0.0,1.0,291.8125,777.5)" opacity="1.0"><path id="ProcessOnPath1064" d="M0.0 0.0L359.375 0.0L359.375 62.5L0.0 62.5Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1065" transform="matrix(1.0,0.0,0.0,1.0,10.0,6.875)"><text id="ProcessOnText1066" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="169.6875" y="13.325">表结构存在企业标识字段 domain</text><text id="ProcessOnText1067" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="169.6875" y="29.575"></text><text id="ProcessOnText1068" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="169.6875" y="45.825">通过 QY_DOMAIN 来读取对应企业的数据</text></g></g><g id="ProcessOnG1069" transform="matrix(1.0,0.0,0.0,1.0,291.8125,890.5)" opacity="1.0"><path id="ProcessOnPath1070" d="M0.0 0.0L359.375 0.0L359.375 44.5L0.0 44.5Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="#ffffff"/><g id="ProcessOnG1071" transform="matrix(1.0,0.0,0.0,1.0,10.0,14.125)"><text id="ProcessOnText1072" fill="#000000" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="middle" font-size="13" x="169.6875" y="13.325">TP 的开发模式</text></g></g><g id="ProcessOnG1073"><path id="ProcessOnPath1074" d="M471.5 747.0L471.5 762.25L471.5 762.25L471.5 762.2639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" fill="none" marker-end="url(#ProcessOnMarker1075)"/></g><g id="ProcessOnG1077"><path id="ProcessOnPath1078" d="M471.5 840.0L471.5 865.25L471.5 865.25L471.5 875.2639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" fill="none" marker-end="url(#ProcessOnMarker1079)"/></g><g id="ProcessOnG1081" transform="matrix(1.0,0.0,0.0,1.0,176.0,673.0)" opacity="1.0"><path id="ProcessOnPath1082" d="M0.0 0.0L591.0 0.0L591.0 290.0L0.0 290.0Z" stroke="#323232" stroke-width="2.0" stroke-dasharray="10.0 4.0" opacity="1.0" fill="none"/></g><g id="ProcessOnG1083"><path id="ProcessOnPath1084" d="M471.5 596.0L471.5 634.5L471.5 634.5L471.5 657.7639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" fill="none" marker-end="url(#ProcessOnMarker1085)"/></g><g id="ProcessOnG1087"><path id="ProcessOnPath1088" d="M333.0 596.0L333.0 634.5L333.0 634.5L333.0 657.7639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="10.0 4.0 2.0 4.0" fill="none" marker-end="url(#ProcessOnMarker1089)"/></g><g id="ProcessOnG1091"><path id="ProcessOnPath1092" d="M628.0 596.0L628.0 634.5L628.0 634.5L628.0 657.7639320225002" stroke="#323232" stroke-width="2.0" stroke-dasharray="10.0 4.0 2.0 4.0" fill="none" marker-end="url(#ProcessOnMarker1093)"/></g><g id="ProcessOnG1095" transform="matrix(1.0,0.0,0.0,1.0,176.0,1196.0)" opacity="1.0"><path id="ProcessOnPath1096" d="M20.0 0.0L0.0 0.0L0.0 119.0L20.0 119.0" stroke="#323232" stroke-width="2.0" stroke-dasharray="none" opacity="1.0" fill="none"/><path id="ProcessOnPath1097" d="M0.0 0.0L733.0 0.0L733.0 119.0L0.0 119.0Z" stroke="#323232" stroke-width="0.0" stroke-dasharray="none" opacity="1.0" fill="none"/><g id="ProcessOnG1098" transform="matrix(1.0,0.0,0.0,1.0,10.0,2.625)"><text id="ProcessOnText1099" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="13.325">目录结构:</text><text id="ProcessOnText1100" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="29.575"></text><text id="ProcessOnText1101" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="45.825">/_DOCS_ 框架的简明文档、开发规则</text><text id="ProcessOnText1102" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="62.075">/Common 默认的应用、公共对外的接口,当访问的应用不存在则会访问改目录,涉及选人等组件的接口也存放于此</text><text id="ProcessOnText1103" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="78.325">/Demo 示例应用代码</text><text id="ProcessOnText1104" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="94.575">/ThinkPHP ThinkPHP 框架代码目录</text><text id="ProcessOnText1105" fill="#0000ff" font-weight="normal" font-style="normal" text-decoration="blink" font-family="微软雅黑" text-anchor="start" font-size="13" x="0.0" y="110.825">/www 入口目录</text></g></g></g></g></svg>