| | |
| | | <template> |
| | | <view class="content"> |
| | | <view class="uni-page-modal-3018"> |
| | | <view class="v-area" v-for="(classattr,index) in classAttrList"> |
| | | <div class="class_attr_title" style="display: none;"> |
| | | <div class="title_line"></div> |
| | |
| | | </div> |
| | | |
| | | </view> |
| | | <button type="default" @tap="cancel" class="btn_cancel">取消</button> |
| | | <button type="default" @tap="sava" class="btn_add">{{title}}</button> |
| | | |
| | | <view class="v-bottom"><button type="default" @tap="cancel" |
| | | class="btn_cancel">{{translateSys('cancel')}}</button> |
| | | <button type="default" @tap="sava" class="btn_add">{{title}}</button> |
| | | </view> |
| | | <!-- 普通弹窗 top bottom center left right --> |
| | | <view> |
| | | <uni-popup class="view-popup" ref="popup" background-color="#fff" @change="popupChange"> |
| | |
| | | </view> |
| | | </view> |
| | | <view class="popup-footer"> |
| | | <button type="default" @tap="popup_sava" class="btn_popup_add">确定</button> |
| | | <button type="default" @tap="popup_cancel" class="btn_popup_cancel">取消</button> |
| | | <button type="default" @tap="popup_sava" class="btn_popup_add">{{translateSys('ok')}}</button> |
| | | <button type="default" @tap="popup_cancel" |
| | | class="btn_popup_cancel">{{translateSys('cancel')}}</button> |
| | | </view> |
| | | </view> |
| | | </uni-popup> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | title: '新增', |
| | | title: this.translateSys('add2'), |
| | | param: {}, |
| | | type: '', |
| | | classAttrList: [], |
| | |
| | | popupParam: {}, |
| | | } |
| | | }, |
| | | mounted() { |
| | | console.log("3018 mounted"); |
| | | }, |
| | | onLoad(options) { |
| | | // console.log(options); |
| | | console.log("3018", options); |
| | | uni.setNavigationBarTitle({ |
| | | title: options.titlename |
| | | }); //设置顶部标题 |
| | |
| | | console.log(param); |
| | | if (!param.EditDlgMode) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: "该功能点未配置编辑窗口,请重新配置!", |
| | | title: this.translateSys('tip'), |
| | | content: this.translate('function_not_edit_dlg'), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | uni.navigateBack({ |
| | | delta: 1, //返回层数,2则上上页 |
| | | }); |
| | | return; |
| | | } |
| | | if (!param.Edit_dlg.Name) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: "该功能点未配置窗口样式,请重新配置!", |
| | | title: this.translateSys('tip'), |
| | | content: this.translate('function_not_edit_dlg'), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | uni.navigateBack({ |
| | | delta: 1, //返回层数,2则上上页 |
| | | }); |
| | | return; |
| | | } |
| | | this.$data.param = param; |
| | | var edit_dlg = { |
| | | Model: param.EditDlgMode, |
| | | Name: param.Edit_dlg.Name |
| | | } |
| | | var dataInfo = { |
| | | class_id: param.clsid, |
| | | class_name: '', |
| | | group_name: '' |
| | | }; |
| | | var $this = this; |
| | | $this.$store.state.thisareaFuncID = param.clsid; |
| | | // console.log($this.$store.getters.getclassAttrList); |
| | | //获取 |
| | | if ($this.$store.getters.getclassAttrList) { |
| | | $this.$data.classAttrList = $this.$store.getters.getclassAttrList; |
| | | $this.classGridStyleInfo(); |
| | | } else |
| | | $this.$store.dispatch('classAttrGetList', dataInfo).then(success => { |
| | | // console.log(success); |
| | | if (success.err_code == 0) { |
| | | $this.$data.classAttrList = success.result; |
| | | success.result.forEach(async (group, index) => { |
| | | group.attr_list.forEach(async (attr, key) => { |
| | | if (utils.classUtils.attrTypeIsDict((attr.type)) { |
| | | await $this.DictItemGetList(attr, key, index); |
| | | } |
| | | }); |
| | | }); |
| | | setTimeout(function() { |
| | | $this.classGridStyleInfo(); |
| | | }, 500); |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误1", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: "错误1.1", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | }); |
| | | }); |
| | | this.loadData() |
| | | |
| | | }, |
| | | |
| | | methods: { |
| | | setData: function(obj) { |
| | | let that = this; |
| | | let keys = []; |
| | | let val, data; |
| | | |
| | | Object.keys(obj).forEach(function(key) { |
| | | keys = key.split("."); |
| | | val = obj[key]; |
| | | data = that.$data; |
| | | keys.forEach(function(key2, index) { |
| | | if (index + 1 == keys.length) { |
| | | that.$set(data, key2, val); |
| | | } else { |
| | | if (!data[key2]) { |
| | | that.$set(data, key2, {}); |
| | | } |
| | | } |
| | | data = data[key2]; |
| | | }); |
| | | }); |
| | | }, |
| | | async loadData() { |
| | | const param = this.param |
| | | var edit_dlg = { |
| | | Model: param.EditDlgMode, |
| | | Name: param.Edit_dlg.Name |
| | | } |
| | | var dataInfo = { |
| | | class_id: this.param.clsid, |
| | | class_name: '', |
| | | group_name: '' |
| | | }; |
| | | var $this = this; |
| | | $this.$store.state.thisareaFuncID = param.clsid; |
| | | // console.log($this.$store.getters.getclassAttrList); |
| | | //获取 |
| | | if ($this.$store.getters.getclassAttrList) { |
| | | $this.$data.classAttrList = $this.$store.getters.getclassAttrList; |
| | | $this.classGridStyleInfo(); |
| | | } else { |
| | | $this.$store.dispatch('classAttrGetList', dataInfo) |
| | | .then((success) => { |
| | | if (success.err_code == 0) { |
| | | $this.$data.classAttrList = success.result; |
| | | success.result.forEach(async (group, index) => { |
| | | group.attr_list.forEach(async (attr, key) => { |
| | | if (utils.classUtils.attrTypeIsDict(attr.type)) { |
| | | await $this.DictItemGetList(attr, key, |
| | | index); |
| | | } |
| | | }); |
| | | }); |
| | | setTimeout(function() { |
| | | $this.classGridStyleInfo(); |
| | | }, 500); |
| | | } else { |
| | | uni.showModal({ |
| | | title: this.translateSys('error') + " 1", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: this.translateSys('error') + " 1.1", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | } |
| | | console.log(this.$data.param); |
| | | }, |
| | | async DictItemGetList(attr, key, index) { //Mobox3得到字典项列表 |
| | | this.data = []; |
| | | var $this = this; |
| | |
| | | |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误1.2", |
| | | title: this.translateSys('error') + " 1.2", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: "错误1.3", |
| | | title: this.translateSys('error') + " 1.3", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | }, |
| | |
| | | $this.viewParam(); |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误1.4", |
| | | title: this.translateSys('error') + " 1.4", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | console.log(ex); |
| | | uni.showModal({ |
| | | title: "错误1.5", |
| | | title: this.translateSys('error') + " 1.5", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | } |
| | |
| | | DispName: attr.disp_name, |
| | | LuaAttr: attr.lua_attr, |
| | | Desc: attr.desc, |
| | | ActionDef: attr.action_def ? Base64.decode(attr.action_def) : '', |
| | | ActionDef: attr.action_def ? Base64.decode(attr |
| | | .action_def) : '', |
| | | Multilingual: attr.multilingual, |
| | | RefCondition: attr.ref_condition, |
| | | GroupName: data.group, |
| | |
| | | if (ca.select == true) |
| | | ca.Value = []; //ca.dictitem[0].CN_S_NAME; |
| | | else |
| | | ca.Value = '请选择'; //ca.dictitem[0].CN_S_NAME; |
| | | ca.Value = this.translateSys( |
| | | "select"); //ca.dictitem[0].CN_S_NAME; |
| | | var dictitemlist = []; |
| | | for (var d = 0; d < ca.dictitem.length; d++) { |
| | | ca.dictitem[d].label = ca.dictitem[d].CN_S_NAME; |
| | |
| | | ca.Value = ca.dictitem[d].CN_S_NAME; |
| | | } |
| | | } |
| | | if(utils.classUtils.attrTypeIsDate(ca.Type)){ |
| | | if (utils.classUtils.attrTypeIsDateTime(ca.Type)) { |
| | | var nowDate = new Date(); |
| | | var date = { |
| | | year: nowDate.getFullYear(), |
| | | month: nowDate.getMonth() + 1, |
| | | day: nowDate.getDate() |
| | | } |
| | | ca.Value = date.year + '-' + (date.month >= 10 ? date.month : '0' + date |
| | | .month) + '-' + (date.day >= 10 ? date.day : '0' + date.day); |
| | | ca.Value = date.year + '-' + (date.month >= 10 ? date.month : |
| | | '0' + |
| | | date |
| | | .month) + '-' + (date.day >= 10 ? date.day : '0' + date |
| | | .day); |
| | | } |
| | | if (utils.classUtils.attrTypeIsObjRefMulti(ca.Type)) { |
| | | ca.RelClsList = ca.RelCls; |
| | | ca.Value = '请'; |
| | | ca.Value = this.translateSys('please'); |
| | | } |
| | | if(utils.classUtils.attrTypeIsRegion(ca.Type)) |
| | | ca.Value = '请选择'; |
| | | if (utils.classUtils.attrTypeIsRegion(ca.Type)) |
| | | ca.Value = this.translateSys("select"); |
| | | if (utils.classUtils.attrTypeIsBool(ca.Type)) |
| | | ca.Value = false; |
| | | |
| | |
| | | |
| | | } else { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: "未找到可显示的的属性", |
| | | title: this.translateSys('tip'), |
| | | content: this.translate('no_find_attr_diaplay'), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }, |
| | |
| | | // } |
| | | // $this.$data.popupParam= popupParam; |
| | | // return; |
| | | var before_click_button = $this.$data.classAttrList[index].Attr[iindex].before_click_button; |
| | | var before_click_button = $this.$data.classAttrList[index].Attr[iindex] |
| | | .before_click_button; |
| | | var button_callback = $this.$data.classAttrList[index].Attr[iindex].button_callback; |
| | | if (!before_click_button) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: "before_click_button-event_id为空!", |
| | | title: this.translateSys('tip'), |
| | | content: this.translate("icon_click_event_empty"), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return; |
| | | } |
| | | if (!button_callback) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: "button_callback-event_id为空!", |
| | | title: this.translateSys('tip'), |
| | | content: this.translate("icon_click_event_empty"), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return; |
| | | } |
| | | this.DataObjRunCustomEvent_Return(before_click_button, data_attr, button_callback, index, iindex); |
| | | this.DataObjRunCustomEvent_Return(before_click_button, data_attr, button_callback, index, |
| | | iindex); |
| | | }, |
| | | popupChange(e) { |
| | | console.log('当前模式:' + e.type + ',状态:' + e.show); |
| | |
| | | } |
| | | if (!$this.$data.popupParam) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | title: this.translateSys('tip'), |
| | | content: "popupParam为空!", |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return; |
| | | } |
| | | $this.$data.classAttrList[$this.$data.popupParam.index].Attr[$this.$data.popupParam.iindex].Value = name; |
| | | $this.$data.classAttrList[$this.$data.popupParam.index].Attr[$this.$data.popupParam.iindex] |
| | | .Value = |
| | | name; |
| | | console.log(data); |
| | | var callback_eventid = $this.$data.popupParam.button_callback.trim(); |
| | | var info = { |
| | |
| | | //console.log(e.target) |
| | | getApp().onScan((result) => { |
| | | console.log(result); |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value = |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset[ |
| | | 'iindex']] |
| | | .Value = |
| | | result.decodedata; |
| | | uni.hideKeyboard(); |
| | | this.onevent($ele, result.decodedata); |
| | |
| | | }, |
| | | ondateTime(e) { |
| | | //console.log(e.target) |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value = e.target |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | .Value = e |
| | | .target |
| | | .value; |
| | | }, |
| | | onchange(e) { |
| | | // console.log(e.target); |
| | | var value = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].dictitem[e |
| | | .target.value]; |
| | | var data_attr = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']]; |
| | | var value = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset[ |
| | | 'iindex']] |
| | | .dictitem[e |
| | | .target.value]; |
| | | var data_attr = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset[ |
| | | 'iindex']]; |
| | | // console.log(data_attr); |
| | | if (value.Name != data_attr.Value) { |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value = value |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | .Value = |
| | | value |
| | | .Name; |
| | | // console.log(this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value); |
| | | var eventid = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | var eventid = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target |
| | | .dataset[ |
| | | 'iindex']] |
| | | .action; |
| | | if (eventid) { |
| | | // self.event_no_sub = 1; |
| | |
| | | for (var j = 0; j < attr.length; j++) { |
| | | var ar = attr[j]; |
| | | req.push(this.formatAttr(ar)) |
| | | |
| | | } |
| | | } |
| | | var info = { |
| | |
| | | var attr = attrlist[i].Attr; |
| | | for (var j = 0; j < attr.length; j++) { |
| | | var ar = attr[j]; |
| | | if (utils.classUtils.attrTypeIsDict(ar.Type)) |
| | | if (utils.classUtils.attrTypeIsDict(ar.Type)) |
| | | req.push({ |
| | | attr: ar.Name, |
| | | value: itemvalue.Name |
| | |
| | | }, |
| | | onevent(e, decodedata) { |
| | | // console.log(e.target); |
| | | var data_attr = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']]; |
| | | var data_attr = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset[ |
| | | 'iindex']]; |
| | | // console.log(decodedata); |
| | | if (e.target.value != data_attr.Value) { |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value = |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | .Value = |
| | | decodedata ? decodedata : e.target.value; |
| | | var eventid = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | var eventid = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target |
| | | .dataset[ |
| | | 'iindex']] |
| | | .action; |
| | | if (eventid) { |
| | | // self.event_no_sub = 1; |
| | |
| | | oncheck(e) { |
| | | // console.log(e.target); |
| | | var ischecked = e.target.dataset.ischeck ? false : true; |
| | | var data_attr = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']]; |
| | | var data_attr = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset[ |
| | | 'iindex']]; |
| | | // console.log(data_attr); |
| | | if (ischecked != data_attr.Value) { |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value = ischecked; |
| | | var eventid = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | .Value = |
| | | ischecked; |
| | | var eventid = this.$data.classAttrList[e.target.dataset['index']].Attr[e.target |
| | | .dataset[ |
| | | 'iindex']] |
| | | .action; |
| | | if (eventid) { |
| | | // self.event_no_sub = 1; |
| | |
| | | addresschange(e) { |
| | | // console.log(e.target); |
| | | console.log(e.data.join(';')) |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value = e.data.join( |
| | | ';'); |
| | | this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']] |
| | | .Value = e.data |
| | | .join( |
| | | ';'); |
| | | }, |
| | | classAttr_AddPer(index, iindex) { |
| | | var param = { |
| | |
| | | AddPer(data, param) { |
| | | // console.log(param); |
| | | console.log(data); |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].Value = data[0].Name; |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].ValID = data[0].Login + ';' + |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].Value = data[ |
| | | 0].Name; |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].ValID = data[ |
| | | 0] |
| | | .Login + ';' + |
| | | data[0].Name; |
| | | |
| | | var eventid = $this.$data.classAttrList[param.index].Attr[param.iindex].action; |
| | | var eventid = $this.$data.classAttrList[param.index].Attr[param.iindex] |
| | | .action; |
| | | if (eventid) { |
| | | eventid = eventid.trim(); |
| | | if (eventid) { |
| | |
| | | classAttr_AddRef(e) { |
| | | console.log(e.target); |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: "此功能还未实现!", |
| | | title: this.translateSys('tip'), |
| | | content: this.translateSys('unrealized'), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | // var value=this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].RelCls[e.target.value]; |
| | | // this.$data.classAttrList[e.target.dataset['index']].Attr[e.target.dataset['iindex']].Value=value; |
| | |
| | | AddPer(data, param) { |
| | | // console.log(param); |
| | | // console.log(data); |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].Value = data[0].Name; |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].ValID = data[0].ID + ';' + |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].Value = data[ |
| | | 0].Name; |
| | | $this.$data.classAttrList[param.index].Attr[param.iindex].ValID = data[ |
| | | 0].ID + |
| | | ';' + |
| | | data[0].Name; |
| | | |
| | | var eventid = $this.$data.classAttrList[param.index].Attr[param.iindex].action; |
| | | var eventid = $this.$data.classAttrList[param.index].Attr[param.iindex] |
| | | .action; |
| | | if (eventid) { |
| | | eventid = eventid.trim(); |
| | | if (eventid) { |
| | |
| | | }, |
| | | add() { |
| | | uni.showLoading({ |
| | | title: "加载中...", |
| | | title: this.translateSys("loading"), |
| | | mask: true |
| | | }); |
| | | var req = []; |
| | |
| | | var attr = attrlist[i].Attr; |
| | | for (var j = 0; j < attr.length; j++) { |
| | | var ar = attr[j]; |
| | | if (ar.Value == '请选择' || ar.Value == '——请选择——') ar.Value = ''; |
| | | if (utils.classUtils.attrTypeIsDict(ar.Type)) { |
| | | if (ar.Value == this.translateSys("select") || ar.Value == '——' + this |
| | | .translateSys( |
| | | "select") + '——') ar.Value = ''; |
| | | if (utils.classUtils.attrTypeIsDict(ar.Type)) { |
| | | if (ar.select == true) { //判断下拉是否多选 |
| | | var valStr = ""; |
| | | for (var v in ar.Value) { |
| | |
| | | name: ar.Name, |
| | | value: ar.Value |
| | | }); |
| | | } else |
| | | { |
| | | } else { |
| | | const node = this.formatAttr(ar) |
| | | req.push({ |
| | | name: node.attr, |
| | | value: node.value |
| | | }); |
| | | } |
| | | |
| | | |
| | | |
| | | if (ar.notempty == true && !ar.Value) { |
| | | // if(ar.NotEmpty=='1'){ |
| | | uni.hideLoading(); |
| | | // uni.showToast({title:ar.DispName+'不能为空!',icon:"success",duration:3000}); |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: ar.DispName + '不能为空!', |
| | | title: this.translateSys('tip'), |
| | | content: this.translateSys('quotation_mark_left') + ar.DispName + |
| | | this |
| | | .translateSys('quotation_mark_right') + this.translate( |
| | | "cannot_empty"), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return; |
| | | } |
| | |
| | | 'function': '3000', // 功能点编号 |
| | | cls_id: this.$data.param.clsid, // 功能点主数据类标识 |
| | | 'button': 'top', // top/bottom |
| | | button_name: '新增', |
| | | button_name: this.translateSys('add2'), |
| | | master: { |
| | | cls_id: this.$data.param.clsid, |
| | | } |
| | |
| | | if (action.ret == '0') { |
| | | if (action.ret != 0) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: '执行脚本失败,' + action.result, |
| | | title: this.translateSys('tip'), |
| | | content: this.translate('execute_script_failed') + |
| | | this |
| | | .translateSys('comma') + this.translate( |
| | | 'result') + |
| | | this |
| | | .translateSys('colon') + action.result, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return; |
| | | } |
| | | if (action.info) { |
| | | uni.showModal({ |
| | | title: "提示", |
| | | content: '执行脚本失败,' + action.info, |
| | | title: this.translateSys('tip'), |
| | | content: this.translate('execute_script_failed') + |
| | | this |
| | | .translateSys('comma') + |
| | | this.translateSys('colon') + action.info, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return; |
| | | } |
| | |
| | | } |
| | | } else |
| | | uni.showToast({ |
| | | title: "创建成功!", |
| | | title: this.translate('create_success'), |
| | | icon: "success", |
| | | duration: 3000 |
| | | }); |
| | | //刷新 |
| | | uni.redirectTo({ |
| | | url: '../modal/3018?param=' + JSON.stringify(this.$data.param) + |
| | | url: '../modal/3018?param=' + JSON.stringify(this.$data |
| | | .param) + |
| | | "&titlename=" + this.$data.title |
| | | }); |
| | | // this.cancel(); |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误", |
| | | title: this.translateSys('error') + " ", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | console.log(ex); |
| | | uni.hideLoading(); |
| | | uni.showModal({ |
| | | title: "提示", |
| | | title: this.translateSys('tip'), |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | }, |
| | |
| | | 'function': '3000', // 功能点编号 |
| | | cls_id: this.$data.param.clsid, // 功能点主数据类标识 |
| | | 'button': 'top', // top/bottom |
| | | button_name: '新增', |
| | | button_name: this.translateSys('add2'), |
| | | master: { |
| | | cls_id: this.$data.param.clsid, // button=bottom时 master的cls_id |
| | | //obj_id: '' // button=bottom时 master的obj_id |
| | |
| | | if (success.err_code == 0) { |
| | | var data = success.result; |
| | | if (data.ret != 0) { |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data |
| | | .err_info : |
| | | data |
| | | .err_info.join('<br/>') : ''; |
| | | if (data.ret == 801) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | else uni.showModal({ |
| | | title: '提示', |
| | | content: tip + ',提示:' + data.ret, |
| | | title: this.translateSys('tip'), |
| | | content: tip + ',' + this.translateSys('tip') + ':' + data |
| | | .ret, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return false |
| | | } else { |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join( |
| | | '<br/>') : ''; |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data |
| | | .info |
| | | .join( |
| | | '<br/>') : ''; |
| | | if (tip) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | |
| | | if (data.action) { |
| | |
| | | if (value) { |
| | | console.log(value); |
| | | for (var i = 0; i < value.length; i++) { |
| | | for (var a = 0; a < this.$data.classAttrList.length; a++) { |
| | | for (var l = 0; l < this.$data.classAttrList[a].Attr |
| | | for (var a = 0; a < this.$data.classAttrList |
| | | .length; a++) { |
| | | for (var l = 0; l < this.$data |
| | | .classAttrList[a] |
| | | .Attr |
| | | .length; l++) { |
| | | var ca = this.$data.classAttrList[a].Attr[l]; |
| | | var ca = this.$data.classAttrList[a] |
| | | .Attr[l]; |
| | | if (value[i].attr == ca.Name) { |
| | | if (utils.classUtils.attrTypeIsDict(ca.Type)) { |
| | | if (utils.classUtils |
| | | .attrTypeIsDict(ca |
| | | .Type)) { |
| | | var dictItemList = []; |
| | | for (var d in value[i].choice_list) { |
| | | var list_val = value[i].choice_list[d]; |
| | | for (var d in value[i] |
| | | .choice_list) { |
| | | var list_val = value[i] |
| | | .choice_list[d]; |
| | | dictItemList.push({ |
| | | "CN_S_NAME": list_val, |
| | | "Name": list_val, |
| | |
| | | } |
| | | |
| | | var length = 0; |
| | | if (!this.$data.refdatastore.filter(function(s) { |
| | | if (!this.$data.refdatastore.filter(function( |
| | | s) { |
| | | return value[i].attr == s.attr |
| | | }).length) { |
| | | length = 1; |
| | | this.$data.refdatastore.push(value[i]); |
| | | } |
| | | if (length == 0) { |
| | | for (var j = 0; j < this.$data.refdatastore.length; j++) { |
| | | if (this.$data.refdatastore[j].attr == value[i].attr) { |
| | | this.$data.refdatastore[j].value = value[i].value; |
| | | for (var j = 0; j < this.$data.refdatastore |
| | | .length; j++) { |
| | | if (this.$data.refdatastore[j].attr == |
| | | value[i] |
| | | .attr) { |
| | | this.$data.refdatastore[j].value = |
| | | value[i] |
| | | .value; |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | if (action_type == 'open_select_userdlg') { |
| | | uni.showModal({ |
| | | title: "错误2.2", |
| | | content: "open_select_userdlg这个action_type还未处理!", |
| | | title: this.translateSys('error') + " 2.2", |
| | | content: this.translateSys( |
| | | "quotation_mark_left") + |
| | | action_type + this.translateSys( |
| | | "quotation_mark_right") + this |
| | | .translate( |
| | | "tip_action_unprocessed"), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | // else if (action_type == 'tip_dlg') { |
| | |
| | | } |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误2", |
| | | title: this.translateSys('error') + " 2", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: "错误2.1", |
| | | title: this.translateSys('error') + " 2.1", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | }, |
| | |
| | | 'function': '3000', // 功能点编号 |
| | | cls_id: this.$data.param.clsid, // 功能点主数据类标识 |
| | | 'button': 'top', // top/bottom |
| | | button_name: '新增', |
| | | button_name: this.translateSys('add2'), |
| | | master: { |
| | | cls_id: this.$data.param.clsid, // button=bottom时 master的cls_id |
| | | //obj_id: '' // button=bottom时 master的obj_id |
| | |
| | | if (success.err_code == 0) { |
| | | var data = success.result; |
| | | if (data.ret != 0) { |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data |
| | | .err_info : |
| | | data |
| | | .err_info.join('<br/>') : ''; |
| | | if (data.ret == 801) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | else uni.showModal({ |
| | | title: '提示', |
| | | content: tip + ',提示:' + data.ret, |
| | | title: this.translateSys('tip'), |
| | | content: tip + ',' + this.translateSys('tip') + ':' + data |
| | | .ret, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return false |
| | | } else { |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join( |
| | | '<br/>') : ''; |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data |
| | | .info |
| | | .join( |
| | | '<br/>') : ''; |
| | | if (tip) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | |
| | | var actionlist = data.action; |
| | |
| | | var result = action.value; |
| | | for (var i = 0; i < result.length; i++) { |
| | | if (result[i].choice_list) { |
| | | for (var c = 0; c < $this.$data.classAttrList.length; c++) { |
| | | for (var c = 0; c < $this.$data.classAttrList |
| | | .length; c++) { |
| | | var attr = $this.$data.classAttrList[c].Attr; |
| | | for (var j = 0; j < attr.length; j++) { |
| | | if (attr[j].Name == result[i].attr) { |
| | | if (utils.classUtils.attrTypeIsDict(attr[j].Type)) { |
| | | if (utils.classUtils.attrTypeIsDict( |
| | | attr[j] |
| | | .Type)) { |
| | | var dictItemList = []; |
| | | for (var d in result[i].choice_list) { |
| | | var val = result[i].choice_list[d]; |
| | | for (var d in result[i] |
| | | .choice_list) { |
| | | var val = result[i] |
| | | .choice_list[d]; |
| | | dictItemList.push({ |
| | | "CN_S_NAME": val, |
| | | "Name": val, |
| | |
| | | } |
| | | } |
| | | } |
| | | for (var c = 0; c < $this.$data.classAttrList.length; c++) { |
| | | for (var c = 0; c < $this.$data.classAttrList |
| | | .length; c++) { |
| | | var attr = $this.$data.classAttrList[c].Attr; |
| | | for (var j = 0; j < attr.length; j++) { |
| | | console.log(attr[j].Name + '==' + result[i].attr); |
| | | console.log(attr[j].Name + '==' + result[i] |
| | | .attr); |
| | | if (attr[j].Name == result[i].attr) { |
| | | attr[j].Value = result[i].value; |
| | | } |
| | |
| | | $this.$data.refdatastore.push(result[i]); |
| | | } |
| | | if (length == 0) { |
| | | for (var j = 0; j < $this.$data.refdatastore.length; j++) { |
| | | if ($this.$data.refdatastore[j].attr == result[i].attr) { |
| | | $this.$data.refdatastore[j].value = result[i].value; |
| | | for (var j = 0; j < $this.$data.refdatastore |
| | | .length; j++) { |
| | | if ($this.$data.refdatastore[j].attr == result[ |
| | | i] |
| | | .attr) { |
| | | $this.$data.refdatastore[j].value = result[ |
| | | i] |
| | | .value; |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | if (length == 0) { |
| | | for (var j = 0; j < $this.$data.refdatastore.length; j++) { |
| | | if ($this.$data.refdatastore[j].attr == result[i].attr) { |
| | | $this.$data.refdatastore[j].value = result[i].value; |
| | | if ($this.$data.refdatastore[j].attr == result[i] |
| | | .attr) { |
| | | $this.$data.refdatastore[j].value = result[i] |
| | | .value; |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误3", |
| | | title: this.translateSys('error') + " 3", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: "错误3.1", |
| | | title: this.translateSys('error') + " 3.1", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | }, |
| | |
| | | 'function': '3000', // 功能点编号 |
| | | cls_id: this.$data.param.clsid, // 功能点主数据类标识 |
| | | 'button': 'top', // top/bottom |
| | | button_name: '新增', |
| | | button_name: this.translateSys('add2'), |
| | | master: { |
| | | cls_id: this.$data.param.clsid, // button=bottom时 master的cls_id |
| | | |
| | |
| | | var attr = attrlist[i].Attr; |
| | | for (var j = 0; j < attr.length; j++) { |
| | | var ar = attr[j]; |
| | | if (ar.Value == '请选择' || ar.Value == '——请选择——') ar.Value = ''; |
| | | if (ar.Value == this.translateSys("select") || ar.Value == '——' + this |
| | | .translateSys( |
| | | "select") + '——') ar.Value = ''; |
| | | req.push(this.formatAttr(ar)); |
| | | } |
| | | } |
| | |
| | | if (success.err_code == 0) { |
| | | var data = success.result; |
| | | if (data.ret != 0) { |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data |
| | | .err_info : |
| | | data |
| | | .err_info.join('<br/>') : ''; |
| | | if (data.ret == 801) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | else uni.showModal({ |
| | | title: '提示', |
| | | content: tip + ',提示:' + data.ret, |
| | | title: this.translateSys('tip'), |
| | | content: tip + ',' + this.translateSys('tip') + ':' + data |
| | | .ret, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return false |
| | | } else { |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join( |
| | | '<br/>') : ''; |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data |
| | | .info |
| | | .join( |
| | | '<br/>') : ''; |
| | | if (tip) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | |
| | | var result = data.result; |
| | |
| | | } |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误4", |
| | | title: this.translateSys('error') + " 4", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: "错误4.1", |
| | | title: this.translateSys('error') + " 4.1", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | }, |
| | |
| | | 'function': '3000', // 功能点编号 |
| | | cls_id: this.$data.param.clsid, // 功能点主数据类标识 |
| | | 'button': 'top', // top/bottom |
| | | button_name: '新增', |
| | | button_name: this.translateSys('add2'), |
| | | master: { |
| | | cls_id: this.$data.param.clsid, // button=bottom时 master的cls_id |
| | | //obj_id: '' // button=bottom时 master的obj_id |
| | |
| | | if (success.err_code == 0) { |
| | | var data = success.result; |
| | | if (data.ret != 0) { |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data |
| | | var tip = data.err_info ? typeof data.err_info == 'string' ? data |
| | | .err_info : |
| | | data |
| | | .err_info.join('<br/>') : ''; |
| | | if (data.ret == 801) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | else uni.showModal({ |
| | | title: '提示', |
| | | content: tip + ',提示:' + data.ret, |
| | | title: this.translateSys('tip'), |
| | | content: tip + ',' + this.translateSys('tip') + ':' + data |
| | | .ret, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | return false |
| | | } else { |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join( |
| | | '<br/>') : ''; |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data |
| | | .info |
| | | .join( |
| | | '<br/>') : ''; |
| | | if (tip) uni.showModal({ |
| | | title: '提示', |
| | | title: this.translateSys('tip'), |
| | | content: tip, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | |
| | | if (data != "") { |
| | |
| | | if (action.action_type == 'open_panel') { |
| | | var d = dialog({ |
| | | title: '<i class="ace-icon fa fa-info-circle"></i> ' + |
| | | '提示', |
| | | content: action.action_type + '此action尚未处理!' |
| | | this.translateSys('tip'), |
| | | content: this.translateSys( |
| | | "quotation_mark_left") + |
| | | action |
| | | .action_type + this.translateSys( |
| | | "quotation_mark_right") + this |
| | | .translate( |
| | | "tip_action_unprocessed") |
| | | }); |
| | | d.show(); |
| | | } else if (action.action_type == 'open_select_userdlg') { |
| | |
| | | data_attr: data_attr |
| | | } |
| | | uni.navigateTo({ |
| | | url: '../selpsn/index?mulit=false¶m=' + JSON.stringify( |
| | | param), |
| | | url: '../selpsn/index?mulit=false¶m=' + |
| | | JSON |
| | | .stringify( |
| | | param), |
| | | events: { |
| | | AddPer(data, param) { |
| | | // console.log(param); |
| | | console.log(data); |
| | | var callback_eventid = param.button_callback |
| | | var callback_eventid = param |
| | | .button_callback |
| | | .trim(); |
| | | var info = { |
| | | eventid: callback_eventid, |
| | |
| | | rclsid: '', |
| | | robjid: '', |
| | | userlogin: '', |
| | | clsid: $this.$data.param.clsid, |
| | | clsid: $this.$data.param |
| | | .clsid, |
| | | objid: "", |
| | | attr: param.req, |
| | | inputparameter: data, |
| | | dataJson: [], |
| | | } |
| | | $this.DataObjRunCustomEvent(info, param.data_attr); |
| | | $this.DataObjRunCustomEvent(info, |
| | | param |
| | | .data_attr); |
| | | } |
| | | } |
| | | }); |
| | | } else if (action.action_type == 'open_data_query_dlg') { |
| | | var d = dialog({ |
| | | title: '<i class="ace-icon fa fa-info-circle"></i> ' + |
| | | '提示', |
| | | content: action.action_type + '此action尚未处理!' |
| | | this.translateSys('tip'), |
| | | content: this.translateSys( |
| | | "quotation_mark_left") + |
| | | action |
| | | .action_type + this.translateSys( |
| | | "quotation_mark_right") + this |
| | | .translate( |
| | | "tip_action_unprocessed") |
| | | }); |
| | | d.show(); |
| | | } else if (action.action_type == 'open_common_dlg') { |
| | | var $this = this; |
| | | if (val.common_dlg_id == 'check_list') { |
| | | $this.$data.check_list = val.config; |
| | | if (val.config.appear_style == 'sideslip') //判断是否是侧滑 |
| | | if (val.config.appear_style == |
| | | 'sideslip') //判断是否是侧滑 |
| | | $this.$data.popupType = 'right'; |
| | | else |
| | | $this.$data.popupType = 'center' |
| | |
| | | } |
| | | $this.$data.popupParam = popupParam; |
| | | } |
| | | } else if (action.action_type == 'open_project_query_dlg') { |
| | | } else if (action.action_type == |
| | | 'open_project_query_dlg') { |
| | | //console.log(action.value.select_range); |
| | | //console.log(action.value.mulit_select); |
| | | var priRel = '-1'; |
| | |
| | | priRel = '1'; |
| | | else if (action.value.select_range == '我创建的') |
| | | priRel = '2'; |
| | | else if (action.value.select_range == '我参与的' || action.value |
| | | else if (action.value.select_range == '我参与的' || action |
| | | .value |
| | | .select_range == '我参加的') |
| | | priRel = '3'; |
| | | else if (action.value.select_range == '我关注的') |
| | |
| | | req: req |
| | | } |
| | | uni.navigateTo({ |
| | | url: '../selPrj/index?relation=' + priRel + '¶m=' + |
| | | url: '../selPrj/index?relation=' + priRel + |
| | | '¶m=' + |
| | | JSON.stringify(param_), |
| | | events: { |
| | | AddPer(data, param) { |
| | | $this.$data.classAttrList[param.index].Attr[param |
| | | .iindex].Value = data[0].Name; |
| | | $this.$data.classAttrList[param.index].Attr[param |
| | | .iindex].ValID = data[0].ID + ';' + data[0] |
| | | $this.$data.classAttrList[param |
| | | .index] |
| | | .Attr[param |
| | | .iindex].Value = data[0] |
| | | .Name; |
| | | var callback_eventid = param.button_callback |
| | | $this.$data.classAttrList[param |
| | | .index] |
| | | .Attr[param |
| | | .iindex].ValID = data[0] |
| | | .ID + ';' + |
| | | data[0] |
| | | .Name; |
| | | var callback_eventid = param |
| | | .button_callback |
| | | .trim(); |
| | | if (callback_eventid) { |
| | | var info = { |
| | |
| | | rclsid: "", |
| | | robjid: "", |
| | | userlogin: "", |
| | | clsid: $this.$data.param.clsid, |
| | | clsid: $this.$data |
| | | .param.clsid, |
| | | objid: "", |
| | | attr: param.req, |
| | | dataJson: [], |
| | | } |
| | | |
| | | $this.DataObjRunCustomEvent(info); |
| | | $this.DataObjRunCustomEvent( |
| | | info); |
| | | } |
| | | } |
| | | } |
| | |
| | | } else { |
| | | var d = dialog({ |
| | | title: '<i class="ace-icon fa fa-info-circle"></i> ' + |
| | | '提示', |
| | | content: action.action_type + '此action尚未处理!' |
| | | this.translateSys('tip'), |
| | | content: this.translateSys( |
| | | "quotation_mark_left") + |
| | | action |
| | | .action_type + this.translateSys( |
| | | "quotation_mark_right") + this |
| | | .translate( |
| | | "tip_action_unprocessed") |
| | | }); |
| | | d.show(); |
| | | } |
| | |
| | | } |
| | | } else { |
| | | uni.showModal({ |
| | | title: "提示5.2", |
| | | content: '调用 before_click_button 脚本返回空,event_id' + eventid, |
| | | title: this.translateSys('tip') + "5.2", |
| | | content: this.translate("execute_script_return_empty"), |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | } |
| | | } else { |
| | | uni.showModal({ |
| | | title: "错误5", |
| | | title: this.translateSys('error') + " 5", |
| | | content: success.err_msg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | } |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | uni.showModal({ |
| | | title: "提示5.1", |
| | | title: this.translateSys('tip') + "5.1", |
| | | content: ex.errMsg, |
| | | showCancel: false, |
| | | confirmText: "取消" |
| | | confirmText: this.translateSys('cancel') |
| | | }); |
| | | }); |
| | | }, |
| | | |
| | | formatAttr(attr) { |
| | | if (utils.classUtils.attrTypeIsObjRefMulti(attr.Type)) //if(ar.Type=='引用对象(多个)') |
| | | if (attr.Value == '请') ar.Value = ''; |
| | | if (attr.Value == this.translateSys('please')) ar.Value = ''; |
| | | if (utils.classUtils.attrTypeIsUser(attr.Type) || utils.classUtils.attrTypeIsProject(attr |
| | | .Type)) //if(ar.Type=='引用人员' || ar.Type=='引用项目') |
| | | return { |
| | |
| | | value: attr.Value ? attr.Value : '' |
| | | }; |
| | | }, |
| | | translate(t) { |
| | | if (typeof this.$t == "function") return this.$t(`page.${t}`) |
| | | else return t; |
| | | }, |
| | | translateSys(t) { |
| | | if (typeof this.$t == "function") return this.$t(`sys.${t}`) |
| | | else return t; |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | <style> |
| | | .class_attr_title { |
| | | font-size: 44rpx; |
| | | padding-bottom: 22rpx; |
| | | position: relative; |
| | | } |
| | | |
| | | .class_attr_title .title_line { |
| | | border-bottom: 2rpx solid #aaa; |
| | | position: relative; |
| | | bottom: -50rpx; |
| | | width: calc(100% - 290rpx); |
| | | margin-left: 100px; |
| | | } |
| | | |
| | | .class_attr_title .title_icon { |
| | | border-radius: 50%; |
| | | width: 100rpx; |
| | | line-height: 64rpx; |
| | | display: inline-block; |
| | | vertical-align: middle; |
| | | padding-top: 10rpx; |
| | | padding-left: 20rpx; |
| | | text-align: center; |
| | | color: #fff; |
| | | } |
| | | |
| | | .class_attr_title i { |
| | | color: #2c6aa0 !important; |
| | | } |
| | | |
| | | .class_attr_title .title_icon i { |
| | | font-size: 80rpx; |
| | | } |
| | | |
| | | .class_attr_title .title { |
| | | padding-right: 22rpx; |
| | | display: inline-block; |
| | | background-color: #fff; |
| | | position: relative; |
| | | bottom: -8rpx; |
| | | } |
| | | |
| | | .class_attr_title .arrow { |
| | | position: absolute; |
| | | top: 6rpx; |
| | | right: 30rpx; |
| | | font-size: 60rpx; |
| | | } |
| | | |
| | | input::-webkit-input-placeholder { |
| | | font-size: 12rpx; |
| | | } |
| | | |
| | | textarea { |
| | | width: 98%; |
| | | border: 1px solid #d5d5d5; |
| | | padding: 10rpx 8rpx 12rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | color: #046db3; |
| | | margin-top: 4px; |
| | | } |
| | | |
| | | input { |
| | | border: 1px solid #d5d5d5; |
| | | width: 98%; |
| | | height: 52rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | color: #046db3; |
| | | padding: 10rpx 8rpx 12rpx; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | margin-top: 4rpx; |
| | | } |
| | | |
| | | .select { |
| | | width: 20px; |
| | | position: absolute; |
| | | opacity: 0; |
| | | } |
| | | |
| | | .class_attr_body .form-group { |
| | | margin: 20rpx 30rpx; |
| | | /* margin-left: -12px; |
| | | margin-right: -12px; */ |
| | | } |
| | | |
| | | .form-group>label[class*="col-"] { |
| | | margin-bottom: 8rpx; |
| | | font-size: 32rpx; |
| | | } |
| | | |
| | | .form-group label { |
| | | vertical-align: middle; |
| | | line-height: 60rpx; |
| | | } |
| | | |
| | | .no-padding-right { |
| | | padding-right: 0 !important; |
| | | } |
| | | |
| | | .col-xs-12 { |
| | | width: 100%; |
| | | } |
| | | |
| | | .tx_title { |
| | | font-size: 32rpx; |
| | | } |
| | | |
| | | .tx_title2 { |
| | | font-size: 32rpx; |
| | | text-align: right; |
| | | display: inline-block; |
| | | vertical-align: -2px; |
| | | } |
| | | |
| | | .text-right { |
| | | margin-right: 20rpx; |
| | | margin-top: -6rpx; |
| | | display: inline-block; |
| | | float: right; |
| | | font-size: 48rpx; |
| | | } |
| | | |
| | | .text-right a, |
| | | .text-right2 a { |
| | | color: #337ab7; |
| | | } |
| | | |
| | | .text-right2 { |
| | | margin: 0; |
| | | vertical-align: -4px; |
| | | margin-left: 9px; |
| | | float: none; |
| | | font-size: 48rpx; |
| | | display: inline-block; |
| | | } |
| | | |
| | | .section_iput { |
| | | border: 1px solid #d5d5d5; |
| | | width: 98%; |
| | | height: 62rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | color: #046db3; |
| | | padding: 10rpx 8rpx 10rpx; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | } |
| | | |
| | | .date_iput { |
| | | border: 1px solid #d5d5d5; |
| | | /* width: 98%; */ |
| | | height: 62rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | color: #046db3; |
| | | padding: 10rpx 8rpx 4rpx; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | } |
| | | |
| | | button.btn_add { |
| | | width: 49.5%; |
| | | margin-top: 50rpx; |
| | | padding: 20rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | float: right; |
| | | display: inline-block; |
| | | } |
| | | |
| | | button.btn_cancel { |
| | | width: 49.5%; |
| | | margin-top: 50rpx; |
| | | padding: 20rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | float: left; |
| | | display: inline-block; |
| | | } |
| | | |
| | | .i_tishi { |
| | | color: red; |
| | | vertical-align: sub; |
| | | font-style: initial; |
| | | margin-left: 20rpx; |
| | | font-size: 17px; |
| | | } |
| | | |
| | | .attr_field { |
| | | display: inline-block; |
| | | vertical-align: middle; |
| | | margin-left: 8px; |
| | | /* width: 71%; */ |
| | | } |
| | | |
| | | .input_vallist { |
| | | max-height: 350rpx; |
| | | overflow-y: auto; |
| | | display: none; |
| | | } |
| | | |
| | | .input_vallist ul { |
| | | /* border: 1px solid red; */ |
| | | padding: 0 20rpx; |
| | | } |
| | | |
| | | .input_vallist ul li { |
| | | list-style: none; |
| | | padding: 20rpx; |
| | | border-bottom: 1px solid #ccc; |
| | | } |
| | | |
| | | .input_vallist ul li a { |
| | | float: right; |
| | | } |
| | | |
| | | .input_vallist ul li a i { |
| | | font-size: 45rpx; |
| | | } |
| | | |
| | | .view-popup { |
| | | position: relative; |
| | | } |
| | | |
| | | |
| | | .popup-content { |
| | | @include flex; |
| | | align-items: center; |
| | |
| | | /* height: 150px; */ |
| | | /* border: 1px solid red; */ |
| | | } |
| | | |
| | | .popup-cont { |
| | | overflow-y: auto; |
| | | /* border: 1px solid red; */ |
| | | } |
| | | |
| | | .popup-height { |
| | | @include height; |
| | | /* width: 200px; */ |
| | | } |
| | | |
| | | .popup-header { |
| | | font-size: 42rpx; |
| | | font-weight: bold; |
| | | margin: 20rpx 20rpx 0px 20rpx; |
| | | } |
| | | |
| | | .view_popup_CheckList { |
| | | margin-bottom: 20rpx; |
| | | } |
| | | |
| | | .popup-footer { |
| | | float: right; |
| | | position: absolute; |
| | | bottom: 0; |
| | | right: 20rpx; |
| | | } |
| | | |
| | | button.btn_popup_add { |
| | | width: 180rpx; |
| | | margin-top: 50rpx; |
| | | margin-right: 20rpx; |
| | | padding: 15rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | /* float: left; */ |
| | | display: inline-block; |
| | | } |
| | | |
| | | button.btn_popup_cancel { |
| | | width: 180rpx; |
| | | margin-top: 50rpx; |
| | | padding: 15rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | /* float: right; */ |
| | | display: inline-block; |
| | | } |
| | | </style> |
| | | <style> |
| | | .touch-item { |
| | | background-color: #F8F9FC; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | width: 100%; |
| | | overflow: hidden |
| | | } |
| | | |
| | | .itemcontent { |
| | | <style lang="scss"> |
| | | .uni-page-modal-3018 { |
| | | display: flex; |
| | | flex-direction: column; |
| | | padding: 5px 10px; |
| | | border-bottom: 1px solid #eeeeee; |
| | | margin-right: 0; |
| | | margin-left: -100px; |
| | | width: 100%; |
| | | -webkit-transition: all 0.4s; |
| | | transition: all 0.4s; |
| | | -webkit-transform: translateX(100px); |
| | | transform: translateX(100px); |
| | | position: relative; |
| | | } |
| | | height: calc(100vh - 30rpx); |
| | | width: 720rpx; |
| | | flex-direction: column !important; |
| | | padding: 15rpx; |
| | | |
| | | .itembtn { |
| | | width: 100px; |
| | | display: flex; |
| | | flex-direction: column; |
| | | align-items: center; |
| | | justify-content: center; |
| | | background-color: #119bf8; |
| | | color: white; |
| | | position: relative; |
| | | -webkit-transform: translateX(100px); |
| | | transform: translateX(100px); |
| | | -webkit-transition: all 0.4s; |
| | | transition: all 0.4s; |
| | | } |
| | | .v-area { |
| | | width: 100%; |
| | | flex-direction: column !important; |
| | | } |
| | | |
| | | .touch-move-active .itemcontent, |
| | | .touch-move-active .itembtn { |
| | | -webkit-transform: translateX(0); |
| | | transform: translateX(0); |
| | | .v-bottom { |
| | | display: block; |
| | | width: calc(100% - 30rpx); |
| | | padding: 10rpx 15rpx 20rpx 15rpx; |
| | | } |
| | | |
| | | .class_attr_title { |
| | | font-size: 44rpx; |
| | | padding-bottom: 22rpx; |
| | | position: relative; |
| | | } |
| | | |
| | | .class_attr_title .title_line { |
| | | border-bottom: 2rpx solid #aaa; |
| | | position: relative; |
| | | bottom: -50rpx; |
| | | width: calc(100% - 290rpx); |
| | | margin-left: 100px; |
| | | } |
| | | |
| | | .class_attr_title .title_icon { |
| | | border-radius: 50%; |
| | | width: 100rpx; |
| | | line-height: 64rpx; |
| | | display: inline-block; |
| | | vertical-align: middle; |
| | | padding-top: 10rpx; |
| | | padding-left: 20rpx; |
| | | text-align: center; |
| | | color: #fff; |
| | | } |
| | | |
| | | .class_attr_title i { |
| | | color: #2c6aa0 !important; |
| | | } |
| | | |
| | | .class_attr_title .title_icon i { |
| | | font-size: 80rpx; |
| | | } |
| | | |
| | | .class_attr_title .title { |
| | | padding-right: 22rpx; |
| | | display: inline-block; |
| | | background-color: #fff; |
| | | position: relative; |
| | | bottom: -8rpx; |
| | | } |
| | | |
| | | .class_attr_title .arrow { |
| | | position: absolute; |
| | | top: 6rpx; |
| | | right: 30rpx; |
| | | font-size: 60rpx; |
| | | } |
| | | |
| | | input::-webkit-input-placeholder { |
| | | font-size: 12rpx; |
| | | } |
| | | |
| | | textarea { |
| | | width: 98%; |
| | | border: 1px solid #d5d5d5; |
| | | padding: 10rpx 8rpx 12rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | color: #046db3; |
| | | margin-top: 4px; |
| | | } |
| | | |
| | | input { |
| | | border: 1px solid #d5d5d5; |
| | | width: 98%; |
| | | height: 52rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | color: #046db3; |
| | | padding: 10rpx 8rpx 12rpx; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | margin-top: 4rpx; |
| | | } |
| | | |
| | | .select { |
| | | width: 20px; |
| | | position: absolute; |
| | | opacity: 0; |
| | | } |
| | | |
| | | .class_attr_body .form-group { |
| | | margin: 20rpx 30rpx; |
| | | /* margin-left: -12px; |
| | | margin-right: -12px; */ |
| | | } |
| | | |
| | | .form-group>label[class*="col-"] { |
| | | margin-bottom: 8rpx; |
| | | font-size: 32rpx; |
| | | } |
| | | |
| | | .form-group label { |
| | | vertical-align: middle; |
| | | line-height: 60rpx; |
| | | } |
| | | |
| | | .no-padding-right { |
| | | padding-right: 0 !important; |
| | | } |
| | | |
| | | .col-xs-12 { |
| | | width: 100%; |
| | | } |
| | | |
| | | .tx_title { |
| | | font-size: 32rpx; |
| | | } |
| | | |
| | | .tx_title2 { |
| | | font-size: 32rpx; |
| | | text-align: right; |
| | | display: inline-block; |
| | | vertical-align: -2px; |
| | | } |
| | | |
| | | .text-right { |
| | | margin-right: 20rpx; |
| | | margin-top: -6rpx; |
| | | display: inline-block; |
| | | float: right; |
| | | font-size: 48rpx; |
| | | } |
| | | |
| | | .text-right a, |
| | | .text-right2 a { |
| | | color: #337ab7; |
| | | } |
| | | |
| | | .text-right2 { |
| | | margin: 0; |
| | | vertical-align: -4px; |
| | | margin-left: 9px; |
| | | float: none; |
| | | font-size: 48rpx; |
| | | display: inline-block; |
| | | } |
| | | |
| | | .section_iput { |
| | | border: 1px solid #d5d5d5; |
| | | width: 98%; |
| | | height: 62rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | color: #046db3; |
| | | padding: 10rpx 8rpx 10rpx; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | } |
| | | |
| | | .date_iput { |
| | | border: 1px solid #d5d5d5; |
| | | /* width: 98%; */ |
| | | height: 62rpx; |
| | | background: #FFF; |
| | | border-radius: 0 !important; |
| | | color: #046db3; |
| | | padding: 10rpx 8rpx 4rpx; |
| | | font-size: 34rpx; |
| | | font-family: inherit; |
| | | box-shadow: none !important; |
| | | transition-duration: 0.1s; |
| | | } |
| | | |
| | | button.btn_add { |
| | | width: 49.5%; |
| | | margin-top: 50rpx; |
| | | padding: 20rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | float: right; |
| | | display: inline-block; |
| | | } |
| | | |
| | | button.btn_cancel { |
| | | width: 49.5%; |
| | | margin-top: 50rpx; |
| | | padding: 20rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | float: left; |
| | | display: inline-block; |
| | | } |
| | | |
| | | .i_tishi { |
| | | color: red; |
| | | vertical-align: sub; |
| | | font-style: initial; |
| | | margin-left: 20rpx; |
| | | font-size: 17px; |
| | | } |
| | | |
| | | .attr_field { |
| | | display: inline-block; |
| | | vertical-align: middle; |
| | | margin-left: 8px; |
| | | /* width: 71%; */ |
| | | } |
| | | |
| | | .input_vallist { |
| | | max-height: 350rpx; |
| | | overflow-y: auto; |
| | | display: none; |
| | | } |
| | | |
| | | .input_vallist ul { |
| | | /* border: 1px solid red; */ |
| | | padding: 0 20rpx; |
| | | } |
| | | |
| | | .input_vallist ul li { |
| | | list-style: none; |
| | | padding: 20rpx; |
| | | border-bottom: 1px solid #ccc; |
| | | } |
| | | |
| | | .input_vallist ul li a { |
| | | float: right; |
| | | } |
| | | |
| | | .input_vallist ul li a i { |
| | | font-size: 45rpx; |
| | | } |
| | | |
| | | .view-popup { |
| | | position: relative; |
| | | } |
| | | |
| | | |
| | | .popup-cont { |
| | | overflow-y: auto; |
| | | /* border: 1px solid red; */ |
| | | } |
| | | |
| | | |
| | | |
| | | .popup-header { |
| | | font-size: 42rpx; |
| | | font-weight: bold; |
| | | margin: 20rpx 20rpx 0px 20rpx; |
| | | } |
| | | |
| | | .view_popup_CheckList { |
| | | margin-bottom: 20rpx; |
| | | } |
| | | |
| | | .popup-footer { |
| | | float: right; |
| | | position: absolute; |
| | | bottom: 0; |
| | | right: 20rpx; |
| | | } |
| | | |
| | | button.btn_popup_add { |
| | | width: 180rpx; |
| | | margin-top: 50rpx; |
| | | margin-right: 20rpx; |
| | | padding: 15rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | /* float: left; */ |
| | | display: inline-block; |
| | | } |
| | | |
| | | button.btn_popup_cancel { |
| | | width: 180rpx; |
| | | margin-top: 50rpx; |
| | | padding: 15rpx; |
| | | line-height: 1.5; |
| | | background: #27A6E1; |
| | | border: none; |
| | | color: #fff; |
| | | font-size: 38rpx; |
| | | font-weight: bold; |
| | | /* float: right; */ |
| | | display: inline-block; |
| | | } |
| | | |
| | | |
| | | .touch-item { |
| | | background-color: #F8F9FC; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | width: 100%; |
| | | overflow: hidden |
| | | } |
| | | |
| | | .itemcontent { |
| | | display: flex; |
| | | flex-direction: column; |
| | | padding: 5px 10px; |
| | | border-bottom: 1px solid #eeeeee; |
| | | margin-right: 0; |
| | | margin-left: -100px; |
| | | width: 100%; |
| | | -webkit-transition: all 0.4s; |
| | | transition: all 0.4s; |
| | | -webkit-transform: translateX(100px); |
| | | transform: translateX(100px); |
| | | position: relative; |
| | | } |
| | | |
| | | .itembtn { |
| | | width: 100px; |
| | | display: flex; |
| | | flex-direction: column; |
| | | align-items: center; |
| | | justify-content: center; |
| | | background-color: #119bf8; |
| | | color: white; |
| | | position: relative; |
| | | -webkit-transform: translateX(100px); |
| | | transform: translateX(100px); |
| | | -webkit-transition: all 0.4s; |
| | | transition: all 0.4s; |
| | | } |
| | | |
| | | .touch-move-active .itemcontent, |
| | | .touch-move-active .itembtn { |
| | | -webkit-transform: translateX(0); |
| | | transform: translateX(0); |
| | | } |
| | | } |
| | | </style> |