mirror of
https://gitee.com/java110/MicroCommunityWeb.git
synced 2026-02-23 21:36:37 +08:00
支持证书
This commit is contained in:
parent
8b99c0563c
commit
fab0b66cd9
@ -7,6 +7,6 @@
|
||||
</div>
|
||||
<div>
|
||||
<a class="btn btn-primary text-white" v-on:click="this._uploadFile()"><span><vc:i18n name="上传附件" namespace="uploadFile"></vc:i18n></span></a>
|
||||
<input type="file" class="file" accept=".zip,rar" capture="camcorder" id="uploadFile" hidden v-on:change="this._chooseFile($event)">
|
||||
<input type="file" class="file" accept="*" capture="camcorder" id="uploadFile" hidden v-on:change="this._chooseFile($event)">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -39,18 +39,12 @@
|
||||
<input v-model="addSmallWeChatInfo.mchId" type="text" :placeholder="vc.i18n('必填,请填写商户ID','addSmallWeChat')" class="form-control">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <div class="form-group row">-->
|
||||
<!-- <label class="col-sm-2 col-form-label"><span><vc:i18n name="作用范围" namespace="addSmallWeChat"></vc:i18n></span></label>-->
|
||||
<!-- <div class="col-sm-10">-->
|
||||
<!-- <select class="custom-select" v-model="addSmallWeChatInfo.objType">-->
|
||||
<!-- <option selected disabled value="">{{vc.i18n('请选择状态','addSmallWeChat')}}</option>-->
|
||||
<!-- <option v-for="(item,index) in addSmallWeChatInfo.objTypes" :key="index"-->
|
||||
<!-- v-bind:value="item.statusCd">{{item.name}}-->
|
||||
<!-- </option>-->
|
||||
<!-- </select>-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-2 col-form-label"><span><vc:i18n name="商户证书" namespace="addSmallWeChat"></vc:i18n></span></label>
|
||||
<div class="col-sm-10">
|
||||
<vc:create path="frame/uploadFile" callBackListener="addSmallWeChat" callBackFunction="notifyCert" namespace="addSmallWeChat"></vc:create>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-2 col-form-label"><span><vc:i18n name="描述" namespace="addSmallWeChat"></vc:i18n></span></label>
|
||||
@ -72,4 +66,4 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -1,4 +1,4 @@
|
||||
(function (vc) {
|
||||
(function(vc) {
|
||||
|
||||
vc.extends({
|
||||
propTypes: {
|
||||
@ -12,39 +12,42 @@
|
||||
appId: '',
|
||||
appSecret: '',
|
||||
payPassword: '',
|
||||
objType:'1000',
|
||||
objId:'',
|
||||
mchId:'',
|
||||
remarks:'',
|
||||
objTypes:'',
|
||||
types:'',
|
||||
weChatType:''
|
||||
objType: '1000',
|
||||
objId: '',
|
||||
mchId: '',
|
||||
remarks: '',
|
||||
objTypes: '',
|
||||
types: '',
|
||||
weChatType: '',
|
||||
certPath: '',
|
||||
|
||||
}
|
||||
},
|
||||
_initMethod: function () {
|
||||
vc.getDict('small_wechat',"obj_type",function(_data){
|
||||
_initMethod: function() {
|
||||
vc.getDict('small_wechat', "obj_type", function(_data) {
|
||||
vc.component.addSmallWeChatInfo.objTypes = _data;
|
||||
});
|
||||
vc.getDict('small_wechat',"wechat_type",function(_data){
|
||||
vc.getDict('small_wechat', "wechat_type", function(_data) {
|
||||
vc.component.addSmallWeChatInfo.types = _data;
|
||||
});
|
||||
|
||||
},
|
||||
_initEvent: function () {
|
||||
vc.on('addSmallWeChat', 'openAddSmallWeChatModal', function (type) {
|
||||
_initEvent: function() {
|
||||
vc.on('addSmallWeChat', 'openAddSmallWeChatModal', function(type) {
|
||||
console.log(type);
|
||||
vc.component.addSmallWeChatInfo.weChatType = type;
|
||||
$('#addSmallWeChatModel').modal('show');
|
||||
});
|
||||
vc.on('addSmallWeChat', 'notifyCert', function(_param) {
|
||||
$that.addSmallWeChatInfo.certPath = _param.realFileName;
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
addSmallWeChatValidate() {
|
||||
return vc.validate.validate({
|
||||
addSmallWeChatInfo: vc.component.addSmallWeChatInfo
|
||||
}, {
|
||||
'addSmallWeChatInfo.name': [
|
||||
{
|
||||
'addSmallWeChatInfo.name': [{
|
||||
limit: "required",
|
||||
param: "",
|
||||
errInfo: "名称不能为空"
|
||||
@ -55,8 +58,7 @@
|
||||
errInfo: "名称不能超过100位"
|
||||
},
|
||||
],
|
||||
'addSmallWeChatInfo.appId': [
|
||||
{
|
||||
'addSmallWeChatInfo.appId': [{
|
||||
limit: "required",
|
||||
param: "",
|
||||
errInfo: "appId不能为空"
|
||||
@ -67,8 +69,7 @@
|
||||
errInfo: "appId不能超过100位"
|
||||
},
|
||||
],
|
||||
'addSmallWeChatInfo.appSecret': [
|
||||
{
|
||||
'addSmallWeChatInfo.appSecret': [{
|
||||
limit: "required",
|
||||
param: "",
|
||||
errInfo: "应用密钥不能为空"
|
||||
@ -79,8 +80,7 @@
|
||||
errInfo: "应用密钥不能超过200个字符"
|
||||
},
|
||||
],
|
||||
'addSmallWeChatInfo.payPassword': [
|
||||
{
|
||||
'addSmallWeChatInfo.payPassword': [{
|
||||
limit: "required",
|
||||
param: "",
|
||||
errInfo: "支付密码不能为空"
|
||||
@ -91,18 +91,16 @@
|
||||
errInfo: "支付密码不能超过200个字符"
|
||||
},
|
||||
],
|
||||
'addSmallWeChatInfo.mchId': [
|
||||
{
|
||||
limit: "required",
|
||||
param: "",
|
||||
errInfo: "小程序商户id不能为空"
|
||||
}
|
||||
],
|
||||
'addSmallWeChatInfo.mchId': [{
|
||||
limit: "required",
|
||||
param: "",
|
||||
errInfo: "小程序商户id不能为空"
|
||||
}],
|
||||
|
||||
|
||||
});
|
||||
},
|
||||
saveSmallWeChatInfo: function () {
|
||||
saveSmallWeChatInfo: function() {
|
||||
if (!vc.component.addSmallWeChatValidate()) {
|
||||
vc.toast(vc.validate.errInfo);
|
||||
|
||||
@ -118,11 +116,10 @@
|
||||
vc.component.addSmallWeChatInfo.objId = vc.getCurrentCommunity().communityId;
|
||||
vc.http.apiPost(
|
||||
'smallWeChat.saveSmallWeChat',
|
||||
JSON.stringify(vc.component.addSmallWeChatInfo),
|
||||
{
|
||||
JSON.stringify(vc.component.addSmallWeChatInfo), {
|
||||
emulateJSON: true
|
||||
},
|
||||
function (json, res) {
|
||||
function(json, res) {
|
||||
//vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
|
||||
let _json = JSON.parse(json)
|
||||
if (_json.code == '0') {
|
||||
@ -136,34 +133,36 @@
|
||||
vc.message(_json.msg);
|
||||
|
||||
},
|
||||
function (errInfo, error) {
|
||||
function(errInfo, error) {
|
||||
console.log('请求失败处理');
|
||||
|
||||
vc.message(errInfo);
|
||||
|
||||
});
|
||||
},
|
||||
clearAddSmallWeChatInfo: function () {
|
||||
clearAddSmallWeChatInfo: function() {
|
||||
vc.component.addSmallWeChatInfo = {
|
||||
weChatId: '',
|
||||
name: '',
|
||||
appId: '',
|
||||
appSecret: '',
|
||||
payPassword: '',
|
||||
objType:'',
|
||||
objId:'',
|
||||
mchId:'',
|
||||
weChatType:'',
|
||||
types:vc.component.addSmallWeChatInfo.types,
|
||||
remarks:'',
|
||||
objTypes:vc.component.addSmallWeChatInfo.objTypes,
|
||||
|
||||
objType: '',
|
||||
objId: '',
|
||||
mchId: '',
|
||||
weChatType: '',
|
||||
types: vc.component.addSmallWeChatInfo.types,
|
||||
remarks: '',
|
||||
objTypes: vc.component.addSmallWeChatInfo.objTypes,
|
||||
certPath: '',
|
||||
};
|
||||
|
||||
vc.emit('addSmallWeChat', 'uploadFile', 'clearVedio', {})
|
||||
},
|
||||
getObjType:function () {
|
||||
getObjType: function() {
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
})(window.vc);
|
||||
})(window.vc);
|
||||
@ -39,17 +39,12 @@
|
||||
<input v-model="editSmallWeChatInfo.mchId" type="text" :placeholder="vc.i18n('必填,请填写商户ID','editSmallWeChat')" class="form-control">
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="form-group row">
|
||||
<label class="col-sm-2 col-form-label"><span><vc:i18n name="配置" namespace="editSmallWeChat"></vc:i18n></span></label>
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-2 col-form-label"><span><vc:i18n name="商户证书" namespace="editSmallWeChat"></vc:i18n></span></label>
|
||||
<div class="col-sm-10">
|
||||
<select class="custom-select" v-model="editSmallWeChatInfo.objType">
|
||||
<option selected disabled value="">{{vc.i18n('请选择状态','editSmallWeChat')}}</option>
|
||||
<option v-for="(item,index) in editSmallWeChatInfo.objTypes" :key="index"
|
||||
v-bind:value="item.statusCd">{{item.name}}
|
||||
</option>
|
||||
</select>
|
||||
<vc:create path="frame/uploadFile" callBackListener="editSmallWeChat" callBackFunction="notifyCert" namespace="editSmallWeChat"></vc:create>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-sm-2 col-form-label"><span><vc:i18n name="描述" namespace="editSmallWeChat"></vc:i18n></span></label>
|
||||
@ -71,4 +66,4 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -13,7 +13,8 @@
|
||||
objId: '',
|
||||
mchId: '',
|
||||
remarks: '',
|
||||
objTypes: '1000'
|
||||
objTypes: '1000',
|
||||
certPath: ''
|
||||
|
||||
}
|
||||
},
|
||||
@ -28,7 +29,13 @@
|
||||
});
|
||||
$('#editSmallWeChatModel').modal('show');
|
||||
vc.copyObject(_params, vc.component.editSmallWeChatInfo);
|
||||
if ($that.editSmallWeChatInfo.certPath) {
|
||||
vc.emit('editSmallWeChat', 'uploadFile', 'notifyVedio', $that.editSmallWeChatInfo.certPath)
|
||||
}
|
||||
});
|
||||
vc.on('editSmallWeChat', 'notifyCert', function(_param) {
|
||||
$that.editSmallWeChatInfo.certPath = _param.realFileName;
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
editSmallWeChatValidate: function() {
|
||||
@ -137,9 +144,10 @@
|
||||
objId: '',
|
||||
mchId: '',
|
||||
remarks: '',
|
||||
objTypes: '1000'
|
||||
|
||||
objTypes: '1000',
|
||||
certPath: ''
|
||||
}
|
||||
vc.emit('editSmallWeChat', 'uploadFile', 'clearVedio', {});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@ -61,10 +61,10 @@
|
||||
<label class="col-sm-3 col-form-label padding-lr-sm text-right"><span><vc:i18n name="合同类型" namespace="addContract"></vc:i18n></span></label>
|
||||
<div class="col-sm-9 padding-lr-xs">
|
||||
<select class="custom-select" v-model="addContractInfo.contractType" @change="_changeContractType()">
|
||||
<option selected disabled value="">{{vc.i18n('必填','addContract')}},请选择合同类型</option>
|
||||
<option v-for="(item,index) in addContractInfo.contractTypes" :key="index"
|
||||
:value="item.contractTypeId">{{item.typeName}}</option>
|
||||
</select>
|
||||
<option selected disabled value="">{{vc.i18n('必填,请选择合同类型','addContract')}}</option>
|
||||
<option v-for="(item,index) in addContractInfo.contractTypes" :key="index"
|
||||
:value="item.contractTypeId">{{item.typeName}}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -75,10 +75,10 @@
|
||||
<label class="col-sm-3 col-form-label padding-lr-sm text-right"><span><vc:i18n name="甲方" namespace="addContract"></vc:i18n></span></label>
|
||||
<div class="col-sm-9 padding-lr-xs">
|
||||
<select class="custom-select" v-model="addContractInfo.partyA" @change="_changeContractPartyA()">
|
||||
<option selected disabled value="">{{vc.i18n('必填','addContract')}},请选择甲方</option>
|
||||
<option v-for="(item,index) in addContractInfo.contractPartyAs" :key="index" :value="item.partyA">
|
||||
{{item.partyA}}</option>
|
||||
</select>
|
||||
<option selected disabled value="">{{vc.i18n('必填,请选择甲方','addContract')}}</option>
|
||||
<option v-for="(item,index) in addContractInfo.contractPartyAs" :key="index" :value="item.partyA">
|
||||
{{item.partyA}}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -107,9 +107,7 @@
|
||||
<input v-model="addContractInfo.partyB" type="text" disabled :placeholder="vc.i18n('必填,请选择乙方','addContract')" class="form-control">
|
||||
</div>
|
||||
<div class="col-sm-2 padding-lr-xs">
|
||||
<button type="button" class="btn btn-link btn-sm" v-on:click="_searchOwner()">
|
||||
选择
|
||||
</button>
|
||||
<button type="button" class="btn btn-link btn-sm" v-on:click="_searchOwner()">选择</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -35,7 +35,7 @@
|
||||
_initMethod: function() {
|
||||
vc.component.roomInfo.conditions.floorId = vc.getParam("floorId");
|
||||
vc.component.roomInfo.conditions.floorName = vc.getParam("floorName");
|
||||
vc.component.listRoom(DEFAULT_PAGE, DEFAULT_ROW);
|
||||
//vc.component.listRoom(DEFAULT_PAGE, DEFAULT_ROW);
|
||||
//与字典表关联
|
||||
vc.getDict('building_room', "state", function(_data) {
|
||||
vc.component.roomInfo.states = _data;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user