This commit is contained in:
weipengfei 2024-03-29 11:20:59 +08:00
parent db2f611ba2
commit 83e56bb3ff
6 changed files with 44 additions and 30 deletions

View File

@ -184,12 +184,14 @@
setTimeout(() => { setTimeout(() => {
this.fSelecting = false; this.fSelecting = false;
}, 500); }, 500);
console.log("选择图片");
uni.chooseImage({ uni.chooseImage({
count: 1, count: 1,
sizeType: ['original', 'compressed'], sizeType: ['original', 'compressed'],
sourceType: ['album', 'camera'], sourceType: ['album', 'camera'],
success: (r) => { success: (r) => {
console.log("选择图片成功");
// #ifdef MP-ALIPAY // #ifdef MP-ALIPAY
uni.showLoading(); uni.showLoading();
// #endif // #endif
@ -254,7 +256,10 @@
uni.hideLoading(); uni.hideLoading();
} }
}); });
} },
fail: (err) => {
console.log("选择图片错误");
}
}) })
}, },
fUpload() { fUpload() {
@ -1261,7 +1266,7 @@
} }
</script> </script>
<style> <style scoped>
.my-canvas { .my-canvas {
display: flex; display: flex;
position: fixed !important; position: fixed !important;

View File

@ -130,7 +130,13 @@
pickerConfirm(e) { pickerConfirm(e) {
const date = new Date(e.value).format('yyyy-MM-dd'); const date = new Date(e.value).format('yyyy-MM-dd');
if (this.pickStartShow) this.searchParams.section_startTime = date; if (this.pickStartShow) {
this.searchParams.section_startTime = date;
this.searchParams.page = 1;
this.paymentData = [];
this.loadend = false;
this.getData();
}
if (this.pickEndShow) { if (this.pickEndShow) {
if (!this.searchParams.section_startTime) if (!this.searchParams.section_startTime)
this.searchParams.section_startTime = date; this.searchParams.section_startTime = date;

View File

@ -283,7 +283,7 @@
this.product_id = opt.product_id; this.product_id = opt.product_id;
this.import = opt.import; this.import = opt.import;
// if (!opt.product_id) this.showCommodity = true; // if (!opt.product_id) this.showCommodity = true;
this.showCommodity = true;; this.showCommodity = true;
this.initData(); this.initData();
this.initClasiffy(); this.initClasiffy();
if (this.import == 1) { if (this.import == 1) {
@ -652,12 +652,12 @@
productUpdate(this.merId, this.product_id, postData) productUpdate(this.merId, this.product_id, postData)
.then(res => { .then(res => {
hideLoading() hideLoading()
Modal('提交成功', '点击确定,返回商品管理', { Modal('提交成功', '点击确定, 前往商品列表页面').then(() => {
showCancel: false
}).then(() => {
uni.redirectTo({ uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId url: `/pages/product/goodsOnSale/index?mer_id=${this.merId}&type=6`
}) })
}).catch(()=>{
uni.navigateBack()
}) })
}) })
.catch(rej => { .catch(rej => {
@ -668,15 +668,15 @@
productCreate(this.merId, postData) productCreate(this.merId, postData)
.then(res => { .then(res => {
hideLoading(); hideLoading();
Modal('提交成功', '点击确定,返回商品管理', { Modal('提交成功', '点击确定,前往商品列表页面').then(() => {
showCancel: false,
}).then(() => {
if (this.import == 1) { if (this.import == 1) {
uni.$emit('importAttrValueOK', this.setFormData.import_id); uni.$emit('importAttrValueOK', this.setFormData.import_id);
uni.navigateBack(); uni.navigateBack();
} else uni.redirectTo({ } else uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId url: `/pages/product/goodsOnSale/index?mer_id=${this.merId}&type=6`
}) })
}).catch(()=>{
uni.navigateBack()
}) })
}) })
.catch(rej => { .catch(rej => {

View File

@ -652,12 +652,12 @@
productUpdate(this.merId, this.product_id, postData) productUpdate(this.merId, this.product_id, postData)
.then(res => { .then(res => {
hideLoading() hideLoading()
Modal('提交成功', '点击确定,返回商品管理', { Modal('提交成功', '点击确定,前往商品列表页面').then(() => {
showCancel: false
}).then(() => {
uni.redirectTo({ uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId url: `/pages/product/goodsOnSale/index?mer_id=${this.merId}&type=6`
}) })
}).catch(()=>{
uni.navigateBack()
}) })
}) })
.catch(rej => { .catch(rej => {
@ -668,15 +668,15 @@
productCreate(this.merId, postData) productCreate(this.merId, postData)
.then(res => { .then(res => {
hideLoading(); hideLoading();
Modal('提交成功', '点击确定,返回商品管理', { Modal('提交成功', '点击确定,前往商品列表页面').then(() => {
showCancel: false,
}).then(() => {
if (this.import == 1) { if (this.import == 1) {
uni.$emit('importAttrValueOK', this.setFormData.import_id); uni.$emit('importAttrValueOK', this.setFormData.import_id);
uni.navigateBack(); uni.navigateBack();
} else uni.redirectTo({ } else uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId url: `/pages/product/goodsOnSale/index?mer_id=${this.merId}&type=6`
}) })
}).catch(()=>{
uni.navigateBack()
}) })
}) })
.catch(rej => { .catch(rej => {

View File

@ -715,12 +715,12 @@
productUpdate(this.merId, this.product_id, postData) productUpdate(this.merId, this.product_id, postData)
.then(res => { .then(res => {
hideLoading() hideLoading()
Modal('提交成功', '点击确定,返回商品管理', { Modal('提交成功', '点击确定,前往商品列表页面').then(() => {
showCancel: false
}).then(() => {
uni.redirectTo({ uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId url: `/pages/product/goodsOnSale/index?mer_id=${this.merId}&type=6`
}) })
}).catch(()=>{
uni.navigateBack()
}) })
}) })
.catch(rej => { .catch(rej => {
@ -731,15 +731,15 @@
productCreate(this.merId, postData) productCreate(this.merId, postData)
.then(res => { .then(res => {
hideLoading(); hideLoading();
Modal('提交成功', '点击确定,返回商品管理', { Modal('提交成功', '点击确定,前往商品列表页面').then(() => {
showCancel: false,
}).then(() => {
if (this.import == 1) { if (this.import == 1) {
uni.$emit('importAttrValueOK', this.setFormData.import_id); uni.$emit('importAttrValueOK', this.setFormData.import_id);
uni.navigateBack(); uni.navigateBack();
} else uni.redirectTo({ } else uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId url: `/pages/product/goodsOnSale/index?mer_id=${this.merId}&type=6`
}) })
}).catch(()=>{
uni.navigateBack()
}) })
}) })
.catch(rej => { .catch(rej => {

View File

@ -439,7 +439,7 @@
let that = this, let that = this,
value = e.detail.value; value = e.detail.value;
value.source = this.source value.source = this.source;
if (that.load) return; if (that.load) return;
if (that.currentTab == 0) { // if (that.currentTab == 0) { //
// if (value.real_name.length == 0) return this.$util.Tips({ // if (value.real_name.length == 0) return this.$util.Tips({
@ -513,7 +513,10 @@
title: "您暂未设置支付密码,请前往设置!" title: "您暂未设置支付密码,请前往设置!"
}, () => { }, () => {
uni.navigateTo({ uni.navigateTo({
url: "/pages/users/user_modify_pwd/index?type=payPwd" url: "/pages/users/user_modify_pwd/index?type=payPwd",
success: () => {
that.load = false;
}
}); });
}) })
} }