diff --git a/mobile-oa-h5/src/oa/components/OaFlowPreview.vue b/mobile-oa-h5/src/oa/components/OaFlowPreview.vue
new file mode 100644
index 00000000..cad03b08
--- /dev/null
+++ b/mobile-oa-h5/src/oa/components/OaFlowPreview.vue
@@ -0,0 +1,364 @@
+
+
+
审批流程
+
加载中…
+
+ {{ pendingMessage || '必填信息填写后,流程将自动显示' }}
+
+
+
暂无流程配置
+
+
+
+
+ {{ s.name || '-' }}
+
+ {{ signBadgeText(s) }}
+
+
+
{{ s.meta }}
+
{{ s.resolveError }}
+
+
+
+
+ {{ avatarChar(p.nickName) }}
+ {{ p.nickName || p.id }}
+
+
+
+ {{ s.type === 'cc' ? '请选择抄送人' : '请选择审批人' }}
+
+
+
+ 添加
+
+
+
+
+ {{ avatarChar(p.nickName) }}
+ {{ p.nickName || p.id }}
+
+
+
+
+
+
+
+
+
+ 取消
+ {{ pickerTitle }}
+ 确定
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/mobile-oa-h5/src/oa/schema-prep.js b/mobile-oa-h5/src/oa/schema-prep.js
new file mode 100644
index 00000000..44464865
--- /dev/null
+++ b/mobile-oa-h5/src/oa/schema-prep.js
@@ -0,0 +1,45 @@
+import { oaFormOption } from './form-option.js'
+
+function walkRules(rules, fn) {
+ const list = Array.isArray(rules) ? rules : []
+ for (const r of list) {
+ if (!r || typeof r !== 'object') continue
+ fn(r)
+ if (Array.isArray(r.children)) walkRules(r.children, fn)
+ }
+}
+
+/** 与 Web ensureOaUploadRuleProps 同思路的最小版 */
+export function ensureOaUploadRuleProps(rules) {
+ const next = JSON.parse(JSON.stringify(rules || []))
+ walkRules(next, (r) => {
+ if (r.type === 'upload' || r.type === 'fcUpload') {
+ r.props = { ...(r.props || {}) }
+ if (r.props.limit == null) r.props.limit = 9
+ }
+ })
+ return next
+}
+
+export function prepareMobileFormSchema(formSchemaJson) {
+ const schema = formSchemaJson || {}
+ const rawRule = Array.isArray(schema.rule)
+ ? schema.rule
+ : Array.isArray(schema)
+ ? schema
+ : []
+ const rule = ensureOaUploadRuleProps(rawRule)
+ const option = {
+ ...oaFormOption,
+ ...(schema.option || {}),
+ form: {
+ ...(schema.option?.form || {}),
+ labelAlign: 'top',
+ inputAlign: 'left',
+ colon: false
+ },
+ submitBtn: false,
+ resetBtn: false
+ }
+ return { rule, option }
+}
diff --git a/mobile-oa-h5/src/router.js b/mobile-oa-h5/src/router.js
index 4d7108ee..faaf2f8f 100644
--- a/mobile-oa-h5/src/router.js
+++ b/mobile-oa-h5/src/router.js
@@ -1,16 +1,15 @@
import { createRouter, createWebHistory } from 'vue-router'
import FormSink from './views/FormSink.vue'
+import OaStart from './views/OaStart.vue'
export default createRouter({
history: createWebHistory(import.meta.env.BASE_URL),
routes: [
- { path: '/', redirect: '/oa-form-sink' },
- { path: '/oa-form-sink', component: FormSink },
{
- path: '/oa-start',
- component: {
- template: '
oa-start 占位(阶段二)
'
- }
- }
+ path: '/',
+ redirect: (to) => ({ path: '/oa-form-sink', query: to.query, hash: to.hash })
+ },
+ { path: '/oa-form-sink', component: FormSink },
+ { path: '/oa-start', component: OaStart }
]
})
diff --git a/mobile-oa-h5/src/views/OaStart.vue b/mobile-oa-h5/src/views/OaStart.vue
new file mode 100644
index 00000000..53219ae2
--- /dev/null
+++ b/mobile-oa-h5/src/views/OaStart.vue
@@ -0,0 +1,346 @@
+
+
+
{{ appMeta.appName || '发起审批' }}
+
+ 加载模板…
+
+
+
+
+
+
+
+
+
+
+
+