| | |
| | | initVal: card.permission || 'true', |
| | | required: false, |
| | | options: [ |
| | | {value: 'true', text: '继承菜单'}, |
| | | {value: 'true', text: '继承组件'}, |
| | | {value: 'false', text: '禁用'}, |
| | | ], |
| | | forbid: viewType === 'popview' |
| | |
| | | if (value === 'defaultsql') { |
| | | value = this.props.defaultsql |
| | | } else if (value === 'flowstart') { |
| | | value = `/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.modifydate as modifydate_w from (select * from ${setting.tableName} where status=0 and deleted=0 $@ and createuserid=@userid@ @$) a |
| | | value = `/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.works_flow_detail_id,w.modifydate as modifydate_w from (select * from ${setting.tableName} where status=0 and deleted=0 $@ and createuserid=@userid@ @$) a |
| | | inner join (select * from s_my_works_flow where works_flow_code=@works_flow_code@ and status=0 and deleted=0) w on a.id=w.works_flow_id */` |
| | | this.props.addProcess() |
| | | } else if (value === 'flowcheck') { |
| | | value = `/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.modifydate as modifydate_w |
| | | value = `/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.works_flow_detail_id,w.modifydate as modifydate_w |
| | | from (select * from ${setting.tableName} where status=0 and deleted=0 ) a |
| | | inner join (select * from s_my_works_flow where works_flow_code=@works_flow_code@ and status>0 and status<888 and deleted=0) w |
| | | on a.id=w.works_flow_id |
| | |
| | | fields.push({ uuid: Utils.getuuid(), label: '状态', field: 'statusname_w', datatype: 'Nvarchar(50)', fieldlength: 50, type: 'text' }) |
| | | cols.push({ uuid: Utils.getuuid(), Width: 120, label: '状态', field: 'statusname_w', type: 'text', Hide: 'false', IsSort: 'false', fieldlength: 50 }) |
| | | } |
| | | if (!_cols.includes('works_flow_detail_id')) { |
| | | fields.push({ uuid: Utils.getuuid(), label: '流程节点ID', field: 'works_flow_detail_id', datatype: 'Nvarchar(50)', fieldlength: 50, type: 'text' }) |
| | | cols.push({ uuid: Utils.getuuid(), Width: 120, label: '流程节点ID', field: 'works_flow_detail_id', type: 'text', Hide: 'false', IsSort: 'false', fieldlength: 50 }) |
| | | } |
| | | if (!_cols.includes('works_flow_param')) { |
| | | fields.push({ uuid: Utils.getuuid(), label: '流程参数', field: 'works_flow_param', datatype: 'Nvarchar(512)', fieldlength: 512, type: 'text' }) |
| | | cols.push({ uuid: Utils.getuuid(), Width: 120, label: '流程参数', field: 'works_flow_param', type: 'text', Hide: 'true', IsSort: 'false', fieldlength: 512 }) |
| | |
| | | let tableName = this.props.form.getFieldValue('tableName') || '表名' |
| | | |
| | | if (type === 'flowstart') { |
| | | _sql = _sql + `\n/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.modifydate as modifydate_w from (select * from ${tableName} where status=0 and deleted=0 $@ and createuserid=@userid@ @$) a |
| | | _sql = _sql + `\n/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.works_flow_detail_id,w.modifydate as modifydate_w from (select * from ${tableName} where status=0 and deleted=0 $@ and createuserid=@userid@ @$) a |
| | | inner join (select * from s_my_works_flow where works_flow_code=@works_flow_code@ and status=0 and deleted=0) w on a.id=w.works_flow_id */` |
| | | } else if (type === 'flowcheck') { |
| | | _sql = _sql + `\n/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.modifydate as modifydate_w |
| | | _sql = _sql + `\n/* select a.*, w.remark as remark_w, w.statusname as statusname_w,w.status as status_w,w.works_flow_param,w.works_flow_detail_id,w.modifydate as modifydate_w |
| | | from (select * from ${tableName} where status=0 and deleted=0 ) a |
| | | inner join (select * from s_my_works_flow where works_flow_code=@works_flow_code@ and status>0 and status<888 and deleted=0) w |
| | | on a.id=w.works_flow_id |
| | |
| | | )} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | {window.backend && setting.interType === 'system' ? <Col span={8}> |
| | | <Form.Item label="事务"> |
| | | {setting.interType === 'system' ? <Col span={8}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="使用后端sql脚本时有效。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | 事务 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('transact', { |
| | | initialValue: setting.transact || 'false' |
| | | })( |
| | |
| | | components.forEach(item => { |
| | | if (item.type === 'tabs') { |
| | | item.subtabs.forEach(tab => { |
| | | if (tab.hide === 'true') return |
| | | |
| | | let _mainSearch = mainSearch || [] |
| | | |
| | | if (appType !== 'mob') { |
| | |
| | | }) |
| | | } |
| | | } |
| | | |
| | | if (formdata && formdata.findIndex(item => item.type === 'vercode') > -1) { |
| | | formdata.push({ |
| | | type: 'text', |
| | | fieldlen: 50, |
| | | writein: false, |
| | | key: 'mk_timestamp' |
| | | }, { |
| | | type: 'text', |
| | | fieldlen: 50, |
| | | writein: false, |
| | | key: 'mk_send_type' |
| | | }, { |
| | | type: 'text', |
| | | fieldlen: 50, |
| | | writein: false, |
| | | key: 'mk_n_id' |
| | | }) |
| | | } |
| | | // 获取字段键值对 |
| | | formdata && formdata.forEach(form => { |
| | | let _key = form.key.toLowerCase() |
| | |
| | | _type = `decimal(18,2)` |
| | | } |
| | | |
| | | if (['appkey'].includes(_key)) return |
| | | |
| | | _declarefields.push(`@${_key} ${_type}`) |
| | | } |
| | | }) |
| | |
| | | } |
| | | } |
| | | |
| | | if (!_vars.includes(_key)) { |
| | | if (!_vars.includes(_key) && !['appkey'].includes(_key)) { |
| | | _vars.push(_key) |
| | | _declarefields.push(`@${_key} ${col.datatype || 'nvarchar(50)'}`) |
| | | } |
| | |
| | | } |
| | | if (/#position-inner/.test(script)) { |
| | | cell.$innerScript = script |
| | | |
| | | if (window.backend && window.GLOB.CacheData.has('sql_' + cell.uuid) && !/\$backend/.test(script)) { |
| | | window.GLOB.CacheData.delete('sql_' + cell.uuid) |
| | | } |
| | | } |
| | | if (/#position-outer/.test(script)) { |
| | | cell.$outerScript = script |
| | | } |
| | | if (/#position-callback/.test(script)) { |
| | | cell.$callbackScript = script |
| | | |
| | | if (window.backend && window.GLOB.CacheData.has('sql_back_' + cell.uuid) && !/\$backend/.test(script)) { |
| | | window.GLOB.CacheData.delete('sql_back_' + cell.uuid) |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | deffers.push( |
| | | new Promise(resolve => { |
| | | Api.getSystemCacheConfig(param, false).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | deffers.push( |
| | | new Promise(resolve => { |
| | | Api.getSystemCacheConfig(mainparam, false).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | deffers = deffers.map(item => { |
| | | return new Promise(resolve => { |
| | | Api.getSystemCacheConfig(item, false).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | } |
| | | if (/#position-inner/.test(script)) { |
| | | cell.$innerScript = script |
| | | |
| | | if (window.backend && window.GLOB.CacheData.has('sql_' + cell.uuid) && !/\$backend/.test(script)) { |
| | | window.GLOB.CacheData.delete('sql_' + cell.uuid) |
| | | } |
| | | } |
| | | if (/#position-outer/.test(script)) { |
| | | cell.$outerScript = script |
| | | } |
| | | if (/#position-callback/.test(script)) { |
| | | cell.$callbackScript = script |
| | | |
| | | if (window.backend && window.GLOB.CacheData.has('sql_back_' + cell.uuid) && !/\$backend/.test(script)) { |
| | | window.GLOB.CacheData.delete('sql_back_' + cell.uuid) |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | if (/#position-inner/.test(script)) { |
| | | cell.$innerScript = script |
| | | |
| | | if (window.backend && window.GLOB.CacheData.has('sql_' + cell.uuid) && !/\$backend/.test(script)) { |
| | | window.GLOB.CacheData.delete('sql_' + cell.uuid) |
| | | } |
| | | } |
| | | if (/#position-outer/.test(script)) { |
| | | cell.$outerScript = script |
| | | } |
| | | if (/#position-callback/.test(script)) { |
| | | cell.$callbackScript = script |
| | | |
| | | if (window.backend && window.GLOB.CacheData.has('sql_back_' + cell.uuid) && !/\$backend/.test(script)) { |
| | | window.GLOB.CacheData.delete('sql_back_' + cell.uuid) |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | error = '行信息中无工作流参数' |
| | | } |
| | | |
| | | if (!error && btn.verify.flowSql !== 'true' && btn.verify.flowType !== 'start' && line && line.approvalMethod === 'countersign') { |
| | | error = '会签流程需要使用默认脚本' |
| | | } |
| | | |
| | | if (error) { |
| | | status = 0 |
| | | statusName = '异常' |
| | |
| | | return new Promise(resolve => { |
| | | Api.getSystemCacheConfig(item, cache).then(res => { |
| | | if (!res.status) { |
| | | if (res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | | duration: 5 |
| | | }) |
| | | } |
| | | skip = true |
| | | } |
| | | resolve(res) |
| | |
| | | new Promise(resolve => { |
| | | Api.getSystemCacheConfig(param, cache).then(res => { |
| | | if (!res.status) { |
| | | if (res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | | duration: 5 |
| | | }) |
| | | } |
| | | skip = true |
| | | } |
| | | resolve(res) |
| | |
| | | new Promise(resolve => { |
| | | Api.getSystemCacheConfig(mainparam, cache).then(res => { |
| | | if (!res.status) { |
| | | if (res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | | duration: 5 |
| | | }) |
| | | } |
| | | skip = true |
| | | } |
| | | resolve(res) |
| | |
| | | setTimeout(() => { |
| | | Api.getSystemCacheConfig(param, cache).then(res => { |
| | | if (!res.status) { |
| | | if (res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | | duration: 5 |
| | | }) |
| | | } |
| | | skip = true |
| | | } |
| | | resolve(res) |
| | |
| | | deffers.push( |
| | | new Promise(resolve => { |
| | | Api.getSystemCacheConfig(param).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | deffers.push( |
| | | new Promise(resolve => { |
| | | Api.getSystemCacheConfig(mainparam).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | deffers = deffers.map(item => { |
| | | return new Promise(resolve => { |
| | | Api.getSystemCacheConfig(item).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | new Promise(resolve => { |
| | | setTimeout(() => { |
| | | Api.getSystemCacheConfig(param).then(res => { |
| | | if (!res.status) { |
| | | if (!res.status && res.ErrCode !== '-2') { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | |
| | | insert into s_my_works_flow_role (works_flow_id,works_flow_code,userid,works_flow_detail_id,createuserid,CreateUser,CreateStaff,upid,typecharone) |
| | | select @ID@,@works_flow_code@,@userid@,@works_flow_detail_id@,@userid@,@UserName,@FullName,@time_id@,'begin'` |
| | | } else { |
| | | value = `update s_my_works_flow set status=@status@,statusname=@statusname@,works_flow_param=@works_flow_param@,works_flow_detail_id=@works_flow_detail_id@,modifydate=getdate(),upid=@time_id@,modifyuserid=@userid@,modifyuser=@username,modifystaff=@fullname${flowRemark ? ',remark=@' + flowRemark : ''} |
| | | value = `set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg ='' |
| | | begin |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | | select @ErrorCode='E', @retmsg='当前单据已审核,请刷新后重试' |
| | | goto aaa |
| | | end |
| | | |
| | | if @dataM@ !='' |
| | | begin |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg != '' |
| | | begin |
| | | goto goto_mk |
| | | end |
| | | end |
| | | else |
| | | begin |
| | | set @retmsg ='' |
| | | select @retmsg=userid from s_my_works_flow_role where works_flow_id=@id@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | | select @retmsg=workerCode+workerName from BD_workers where id=@retmsg |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限,请联系'+@retmsg+'操作' |
| | | goto aaa |
| | | end |
| | | end |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限' |
| | | goto aaa |
| | | end |
| | | |
| | | goto_mk: |
| | | |
| | | set @retmsg='' |
| | | |
| | | update s_my_works_flow set status=@status@,statusname=@statusname@,works_flow_param=@works_flow_param@,works_flow_detail_id=@works_flow_detail_id@,modifydate=getdate(),upid=@time_id@,modifyuserid=@userid@,modifyuser=@username,modifystaff=@fullname${flowRemark ? ',remark=@' + flowRemark : ''} |
| | | where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 |
| | | insert into s_my_works_flow_log (works_flow_id,works_flow_code,works_flow_name,works_flow_param,status,statusname,works_flow_detail_id,work_group,work_grade,bid,createuserid,CreateUser,CreateStaff,upid${flowRemark ? ',remark' : ''}) |
| | | select @ID@,@works_flow_code@,@works_flow_name@ ,@works_flow_param@,@status@,@statusname@,@works_flow_detail_id@,@work_group@,@work_grade@,@bid@,@UserID@,@UserName,@FullName,@time_id@${flowRemark ? ',@' + flowRemark : ''} |
| | |
| | | let formfields = [] |
| | | _fields = _fields.filter(_f => _f.field) |
| | | _fields.forEach(_f => { |
| | | if (_f.field.toLowerCase() === 'bid') { |
| | | let key = _f.field.toLowerCase() |
| | | if (key === 'bid') { |
| | | hasBid = true |
| | | } |
| | | |
| | | if (fieldArr.includes(_f.field.toLowerCase())) return |
| | | if (fieldArr.includes(key)) return |
| | | |
| | | fieldArr.push(_f.field.toLowerCase()) |
| | | fieldArr.push(key) |
| | | |
| | | formfields.push(_f.field) |
| | | |
| | |
| | | } else { |
| | | _select.push(`@${_f.field}=''`) |
| | | } |
| | | |
| | | if (['appkey'].includes(key)) return |
| | | |
| | | _declare.push(`@${_f.field} ${_type}`) |
| | | }) |
| | |
| | | _select.push(`@${_f.field}=''`) |
| | | } |
| | | |
| | | _declare.push(`@${_f.field} ${_f.datatype}`) |
| | | return |
| | | } |
| | | if (['appkey'].includes(key)) return |
| | | |
| | | _declare.push(`@${_f.field} ${_f.datatype}`) |
| | | } else { |
| | | let _fieldlen = _f.fieldlength || 50 |
| | | |
| | | if (_fieldlen > 4000) { |
| | |
| | | _select.push(`@${_f.field}=''`) |
| | | } |
| | | |
| | | if (['appkey'].includes(key)) return |
| | | |
| | | _declare.push(`@${_f.field} ${_type}`) |
| | | } |
| | | }) |
| | | } |
| | | |
| | |
| | | if @works_flow_countersign@ = 'Y' |
| | | begin |
| | | /* 工作流默认sql(会签) */ |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg ='' |
| | | begin |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | if @retmsg !='' |
| | | begin |
| | | select @ErrorCode='E', @retmsg='当前单据已审核,请刷新后重试' |
| | | goto aaa |
| | | end |
| | | |
| | | set @retmsg ='' |
| | | select @retmsg=userid from s_my_works_flow_role where works_flow_id=@id@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | | select @retmsg=workerCode+workerName from BD_workers where id=@retmsg |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限,请联系'+@retmsg+'操作' |
| | | goto aaa |
| | | end |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限' |
| | | goto aaa |
| | | end |
| | | |
| | | declare @works_flow_statuscharone nvarchar(50),@works_flow_statuschartwo nvarchar(50),@works_flow_statuscharthree nvarchar(50),@works_flow_statuscharfour nvarchar(50),@works_flow_statuscharfive nvarchar(50),@works_flow_key_id nvarchar(50),@works_flow_key_status nvarchar(20),@s_my_works_flow_log_param nvarchar(max),@s_my_works_flow_log_status int,@s_my_works_flow_log_statusname nvarchar(50),@s_my_works_flow_log_detail_id nvarchar(50) |
| | | select @works_flow_statuscharone='',@works_flow_statuschartwo='',@works_flow_statuscharthree='',@works_flow_statuscharfour='',@works_flow_statuscharfive='',@works_flow_key_id='',@works_flow_key_status ='',@s_my_works_flow_log_param='',@s_my_works_flow_log_status=0,@s_my_works_flow_log_statusname='',@s_my_works_flow_log_detail_id='' |
| | | |
| | |
| | | begin |
| | | /* 工作流默认sql(或签) */ |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg ='' |
| | | begin |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | |
| | | if @dataM@ !='' |
| | | begin |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg != '' |
| | | begin |
| | | goto goto_mk |
| | | end |
| | | end |
| | | else |
| | | begin |
| | | set @retmsg ='' |
| | | select @retmsg=userid from s_my_works_flow_role where works_flow_id=@id@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | | select @retmsg=workerCode+workerName from BD_workers where id=@retmsg |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限,请联系'+@retmsg+'操作' |
| | | goto aaa |
| | | end |
| | | end |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限' |
| | | goto aaa |
| | |
| | | error = '行信息中无工作流参数' |
| | | } |
| | | |
| | | if (!error && verify.flowSql !== 'true' && verify.flowType !== 'start' && line && line.approvalMethod === 'countersign') { |
| | | error = '会签流程需要使用默认脚本' |
| | | } |
| | | |
| | | if (error) { |
| | | status = 0 |
| | | statusName = '异常' |
| | |
| | | |
| | | _sql += ` |
| | | /* 工作流默认sql */ |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg ='' |
| | | begin |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | if @retmsg !='' |
| | | begin |
| | | select @ErrorCode='E', @retmsg='当前单据已审核,请刷新后重试' |
| | | goto aaa |
| | | end |
| | | |
| | | set @retmsg ='' |
| | | select @retmsg=userid from s_my_works_flow_role where works_flow_id=@id@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | | select @retmsg=workerCode+workerName from BD_workers where id=@retmsg |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限,请联系'+@retmsg+'操作' |
| | | goto aaa |
| | | end |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限' |
| | | goto aaa |
| | | end |
| | | |
| | | declare ${_declare},@works_flow_key_id nvarchar(50),@works_flow_key_status nvarchar(20),@s_my_works_flow_log_param nvarchar(max),@s_my_works_flow_log_status int,@s_my_works_flow_log_statusname nvarchar(50),@s_my_works_flow_log_detail_id nvarchar(50) |
| | | select ${_select},@works_flow_key_id='',@works_flow_key_status ='',@s_my_works_flow_log_param='',@s_my_works_flow_log_status=0,@s_my_works_flow_log_statusname='',@s_my_works_flow_log_detail_id='' |
| | | |
| | |
| | | _sql += ` |
| | | /* 工作流默认sql */ |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and userid =@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg ='' |
| | | begin |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and userid=@userid@ and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | |
| | | if @dataM@ !='' |
| | | begin |
| | | set @retmsg ='' |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 |
| | | select @retmsg='X' from s_my_works_flow_role where works_flow_id=@ID@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg != '' |
| | | begin |
| | | goto goto_mk |
| | | end |
| | | end |
| | | else |
| | | begin |
| | | set @retmsg ='' |
| | | select @retmsg=userid from s_my_works_flow_role where works_flow_id=@id@ and works_flow_code=@works_flow_code@ and deleted=0 and works_flow_detail_id =@works_flow_detail_id |
| | | |
| | | if @retmsg !='' |
| | | begin |
| | | select @retmsg=workerCode+workerName from BD_workers where id=@retmsg |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限,请联系'+@retmsg+'操作' |
| | | goto aaa |
| | | end |
| | | end |
| | | |
| | | select @retmsg='页面数据已更新,或没有当前单据的审批权限' |
| | | goto aaa |
| | |
| | | // oriIds[item.uuid + item.md5] = item.v_id |
| | | // }) |
| | | // } |
| | | let perm = true |
| | | if (config.permission === 'false' || config.sqlperm === 'false') { |
| | | perm = false |
| | | } |
| | | |
| | | config.allSqls = sqls.map(item => { |
| | | let v_id = _t + getguid() |
| | |
| | | // v_id = oriIds[item.uuid + item.md5] |
| | | // } |
| | | |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${config.permission === 'false' ? '' : item.roleId || ''}`) |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${perm ? item.roleId || '' : ''}`) |
| | | |
| | | return { |
| | | uuid: item.uuid, |
| | |
| | | )} |
| | | </Form.Item> |
| | | </Col> |
| | | {config.permission !== 'false' ? <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="是否检验后端sql的权限,使用后端sql脚本时有效。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | sql验证 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('sqlperm', { |
| | | initialValue: config.sqlperm || 'true' |
| | | })( |
| | | <Radio.Group onChange={(e) => {this.selectChange('sqlperm', e.target.value)}}> |
| | | <Radio value="true">使用</Radio> |
| | | <Radio value="false">不使用</Radio> |
| | | </Radio.Group> |
| | | )} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="数据会缓存到用户本地,方便页面快速呈现。"> |
| | |
| | | // v_id = oriIds[item.uuid + item.md5] |
| | | // } |
| | | |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${item.roleId || ''}`) |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${config.sqlperm === 'false' ? '' : item.roleId || ''}`) |
| | | |
| | | return { |
| | | uuid: item.uuid, |
| | |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="是否检验后端sql的权限,使用后端sql脚本时有效。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | sql验证 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('sqlperm', { |
| | | initialValue: config.sqlperm || 'true' |
| | | })( |
| | | <Radio.Group onChange={(e) => {this.selectChange('sqlperm', e.target.value)}}> |
| | | <Radio value="true">使用</Radio> |
| | | <Radio value="false">不使用</Radio> |
| | | </Radio.Group> |
| | | )} |
| | | </Form.Item> |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="数据会缓存到用户本地,方便页面快速呈现。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | 本地缓存 |
| | |
| | | // v_id = oriIds[item.uuid + item.md5] |
| | | // } |
| | | |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${item.roleId || ''}`) |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${config.sqlperm === 'false' ? '' : item.roleId || ''}`) |
| | | |
| | | return { |
| | | uuid: item.uuid, |
| | |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="是否检验后端sql的权限,使用后端sql脚本时有效。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | sql验证 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('sqlperm', { |
| | | initialValue: config.sqlperm || 'true' |
| | | })( |
| | | <Radio.Group onChange={(e) => {this.selectChange('sqlperm', e.target.value)}}> |
| | | <Radio value="true">使用</Radio> |
| | | <Radio value="false">不使用</Radio> |
| | | </Radio.Group> |
| | | )} |
| | | </Form.Item> |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="数据会缓存到用户本地,方便页面快速呈现。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | 本地缓存 |
| | |
| | | // v_id = oriIds[item.uuid + item.md5] |
| | | // } |
| | | |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${item.roleId || ''}`) |
| | | long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))},${config.sqlperm === 'false' ? '' : item.roleId || ''}`) |
| | | |
| | | return { |
| | | uuid: item.uuid, |
| | |
| | | import React, {Component} from 'react' |
| | | import PropTypes from 'prop-types' |
| | | import { Form, Row, Col, Input, Select, notification, Switch, Radio } from 'antd' |
| | | import { Form, Row, Col, Input, Select, notification, Switch, Radio, Tooltip } from 'antd' |
| | | import { QuestionCircleOutlined } from '@ant-design/icons' |
| | | |
| | | import Api from '@/api' |
| | | import asyncComponent from '@/utils/asyncComponent' |
| | |
| | | </Form.Item> |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="是否检验后端sql的权限,使用后端sql脚本时有效。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | sql验证 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('sqlperm', { |
| | | initialValue: config.sqlperm || 'true' |
| | | })( |
| | | <Radio.Group onChange={(e) => {this.selectChange('sqlperm', e.target.value)}}> |
| | | <Radio value="true">使用</Radio> |
| | | <Radio value="false">不使用</Radio> |
| | | </Radio.Group> |
| | | )} |
| | | </Form.Item> |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label="工作流"> |
| | | {getFieldDecorator('process', { |
| | | initialValue: config.process || 'false' |