| | |
| | | </view> |
| | | </uni-forms-item> |
| | | <!-- 栅格布局 --> |
| | | <uni-row class="demo-uni-row" v-if="item.name=='Layout' && item.show==true"> |
| | | <uni-row class="demo-uni-row" v-if="item.name=='Layout'"> |
| | | <uni-col v-for="(cols,key) in item.setting.colList" |
| | | :span="item.setting.spanList?item.setting.spanList[key]:24 / item.setting.col"> |
| | | <uni-forms-item class="head-form" v-if="cols!=null" :label="cols.label +':'" |
| | | :label-width="cols.labelWidth+'px'"> |
| | | <uni-forms-item class="head-form" v-if="cols!=null && cols.show==true" :label="cols.label +':'" |
| | | :label-width="cols.labelWidth+'px'" > |
| | | <!-- <text class="txt_title" :style="{'width':cols.labelWidth+'px'}">{{cols.label}}:</text> --> |
| | | <span class="form-item-span" v-if="cols.disabled">{{cols.value}}</span> |
| | | <view class="input-wrapper" |
| | |
| | | </a> |
| | | </view> |
| | | </view> |
| | | <button type="default" @tap="sava" class="btn_add" v-if="dropdownBtns.length==0">{{title}}</button> |
| | | <button type="default" @tap="sava" class="btn_add" v-if="dropdownBtns.length==0" :class="saving?'btn_disabled':''" :disabled="saving">{{title}}</button> |
| | | <button type="default" @tap="cancel" class="btn_cancel">{{translateSys('cancel')}}</button> |
| | | |
| | | </view> |
| | |
| | | activity: null, |
| | | receiver: null, |
| | | intentFilter: null, |
| | | content: '' |
| | | content: '', |
| | | saving:false |
| | | }; |
| | | }, |
| | | onNavigationBarButtonTap(e) { |
| | |
| | | $this.setData({ |
| | | head_styledef: styledefHead |
| | | }) |
| | | |
| | | console.log("head_styledef",this.head_styledef) |
| | | if ($this.head_styledef.event?.length > 0) { |
| | | $this.head_styledef.event.forEach(async (a) => { //判断是否是初始化事件 |
| | | if (a.event_id == "initial") { |
| | |
| | | }) |
| | | |
| | | }, |
| | | getUIStyleInfo(info) { //Mobox3数据类界面样式 |
| | | const loginInfo = this.$store.getters.loginid |
| | | const dataSApi = this.$store.getters.getDataSApi |
| | | return new Promise((resolve, reject) => { |
| | | uni.request({ |
| | | url: dataSApi + 'api/class/uistyle/GetInfo?sessionid=' + loginInfo.result |
| | | .session_id, |
| | | data: info, |
| | | method: 'POST', |
| | | dataType: "json", |
| | | success: (_res) => { |
| | | // console.log(_res); |
| | | const ret = _res.data |
| | | if (ret.err_code == 0) { |
| | | resolve(ret); |
| | | } else { |
| | | reject({ |
| | | "errMsg": ret.err_msg |
| | | }); |
| | | } |
| | | }, |
| | | fail: (err) => { |
| | | // console.log(err); |
| | | reject(err); |
| | | } |
| | | }) |
| | | |
| | | }) |
| | | |
| | | }, |
| | | |
| | | async loadInitEvent(eventid) { |
| | | var $this = this; |
| | | if (!eventid.includes('{')) eventid = '{' + eventid + '}'; |
| | |
| | | title: this.translateSys("loading"), |
| | | mask: true |
| | | }); |
| | | var obj_attr = this.head_styledef.form.model; |
| | | this.saving = true |
| | | var obj_attr = this.head_styledef.form.model || []; |
| | | console.log(obj_attr); |
| | | // var req = Object.keys(obj_attr).map((a) => ({ |
| | | // name: a, |
| | |
| | | showCancel: false, |
| | | confirmText: this.translateSys("cancel") |
| | | }); |
| | | this.saving = false |
| | | return; |
| | | } |
| | | if (action.info) { |
| | |
| | | confirmText: this.translateSys("cancel") |
| | | }); |
| | | } |
| | | this.saving = false |
| | | }).catch(ex => { |
| | | console.log(ex); |
| | | this.saving = false |
| | | uni.hideLoading(); |
| | | uni.showModal({ |
| | | title: this.translateSys("tip"), |
| | |
| | | }); |
| | | }, |
| | | afterOK() { |
| | | this.saving = true |
| | | var obj_attr = this.head_styledef.form.model; |
| | | // console.log(obj_attr); |
| | | var input_param = { |
| | |
| | | showCancel: false, |
| | | confirmText: this.translateSys("cancel") |
| | | }); |
| | | this.saving = false |
| | | return false |
| | | } else { |
| | | var tip = data.info ? typeof data.info == 'string' ? data.info : data |
| | |
| | | confirmText: this.translateSys("cancel") |
| | | }); |
| | | } |
| | | this.saving = false |
| | | }).catch(ex => { |
| | | // console.log(ex); |
| | | this.saving = false |
| | | uni.showModal({ |
| | | title: this.translateSys('tip') + "7.1", |
| | | content: ex.errMsg, |
| | |
| | | float: left; |
| | | display: inline-block; |
| | | } |
| | | |
| | | .btn_disabled { |
| | | background-color: #ddd; |
| | | color: #888; |
| | | } |
| | | .btn_cancel { |
| | | width: 45%; |
| | | margin: 0 10rpx; |