diff --git a/config.js b/config.js
index d319b55..c35fa06 100644
--- a/config.js
+++ b/config.js
@@ -1,13 +1,13 @@
// 应用全局配置
module.exports = {
- // baseUrl: 'http://api-dashboard.yudao.iocoder.cn',
+ baseUrl: 'https://sy.hbcjy.com/prod-api',
// baseUrl: 'http://127.0.0.1:48080',
- baseUrl: 'http://192.168.130.193:48080',
+ // baseUrl: 'http://192.168.130.193:48080',
baseApi: '/admin-api',
// 应用信息
appInfo: {
// 应用名称
- name: "yudao-app",
+ name: "农源追溯宝",
// 应用版本
version: "1.0.0",
// 应用logo
diff --git a/main.js b/main.js
index 183fc2a..0fd22b4 100644
--- a/main.js
+++ b/main.js
@@ -6,8 +6,6 @@ import './permission' // permission
import {DICT_TYPE, getDictDataLabel, getDictDatas, getDictDatas2} from "@/utils/dict";
import { getDicts } from "@/api/system/dict/data";
-import uView from '@/uni_modules/uview-ui'
-Vue.use(uView)
// 注意要在use方法之后执行
Vue.use(plugins)
diff --git a/manifest.json b/manifest.json
index 30a8388..34949b7 100644
--- a/manifest.json
+++ b/manifest.json
@@ -41,7 +41,7 @@
},
"quickapp" : {},
"mp-weixin" : {
- "appid" : "wxaf70a5cd03b06c19",
+ "appid" : "wx09c9feedd19378a3",
"setting" : {
"urlCheck" : false,
"es6" : false,
@@ -52,15 +52,16 @@
"subPackages" : true
},
"usingComponents" : true,
- "permission": {
- "scope.userLocation": {
- "desc": "你的位置信息将用于小程序位置接口的效果展示"
- },
- "scope.userFuzzyLocation": {
- "desc": "你的位置信息将用于小程序位置接口的效果展示"
- }
- },
- "requiredPrivateInfos": ["chooseLocation","getLocation"]
+ "permission" : {
+ "scope.userLocation" : {
+ "desc" : "你的位置信息将用于小程序位置接口的效果展示"
+ },
+ "scope.userFuzzyLocation" : {
+ "desc" : "你的位置信息将用于小程序位置接口的效果展示"
+ }
+ },
+ "requiredPrivateInfos" : [ "chooseLocation", "getLocation" ],
+ "lazyCodeLoading": "requiredComponents"
},
"vueVersion" : "2",
"h5" : {
diff --git a/pages.json b/pages.json
index 4882470..fe149ea 100644
--- a/pages.json
+++ b/pages.json
@@ -1,15 +1,18 @@
{
- "pages": [
- {
+ "pages": [{
"path": "pages/login",
"style": {
- "navigationBarTitleText": "登录"
+ "navigationBarTitleText": "登录",
+ "componentPlaceholder": {
+ // "其他分包自定义组件": "占位组件"
+ "verify": "view"
+ }
}
},
{
"path": "pages/index",
"style": {
- "navigationBarTitleText": "芋道移动端框架",
+ "navigationBarTitleText": "",
"navigationStyle": "custom"
}
},
@@ -30,139 +33,6 @@
"style": {
"navigationBarTitleText": "我的"
}
- },
- {
- "path": "pages/mine/avatar/index",
- "style": {
- "navigationBarTitleText": "修改头像"
- }
- },
- {
- "path": "pages/mine/info/index",
- "style": {
- "navigationBarTitleText": "个人信息"
- }
- },
- {
- "path": "pages/mine/info/edit",
- "style": {
- "navigationBarTitleText": "编辑资料"
- }
- },
- {
- "path": "pages/mine/pwd/index",
- "style": {
- "navigationBarTitleText": "修改密码"
- }
- },
- {
- "path": "pages/mine/setting/index",
- "style": {
- "navigationBarTitleText": "应用设置"
- }
- },
- {
- "path": "pages/mine/help/index",
- "style": {
- "navigationBarTitleText": "常见问题"
- }
- },
- {
- "path": "pages/mine/about/index",
- "style": {
- "navigationBarTitleText": "关于我们"
- }
- }, {
- "path": "pages/mine/business/index",
- "style": {
- "navigationBarTitleText": "企业信息"
- }
- }, {
- "path": "pages/mine/base/index",
- "style": {
- "navigationBarTitleText": "基地信息"
- }
- }, {
- "path": "pages/mine/base/baseList",
- "style": {
- "navigationBarTitleText": "基地列表"
- }
- },
- {
- "path": "pages/common/webview/index",
- "style": {
- "navigationBarTitleText": "浏览网页"
- }
- },
- {
- "path": "pages/common/textview/index",
- "style": {
- "navigationBarTitleText": "浏览文本"
- }
- },
- {
- "path": "pages/traceability-code/inventory",
- "style": {
- "navigationBarTitleText": "库存溯源码"
- }
- },
- {
- "path": "pages/traceability-code/sales",
- "style": {
- "navigationBarTitleText": "销售溯源码"
- }
- },
- {
- "path": "pages/traceability-product/index",
- "style": {
- "navigationBarTitleText": "溯源产品"
- }
- },
- {
- "path": "pages/traceability-product/delivery/index",
- "style": {
- "navigationBarTitleText": "配送记录"
- }
- },
- {
- "path": "pages/traceability-product/delivery/deliveryEdit",
- "style": {
- "navigationBarTitleText": "产品配送"
- }
- },
- {
- "path": "pages/traceability-product/sales/index",
- "style": {
- "navigationBarTitleText": "销售记录"
- }
- },
- {
- "path": "pages/traceability-product/sales/salesEdit",
- "style": {
- "navigationBarTitleText": "产品销售"
- }
- },
- {
- "path": "pages/traceability-product/loss/index",
- "style": {
- "navigationBarTitleText": "报损记录"
- }
- },
- {
- "path": "pages/traceability-product/loss/lossEdit",
- "style": {
- "navigationBarTitleText": "产品报损"
- }
- }, {
- "path": "pages/traceability-product/machining/index",
- "style": {
- "navigationBarTitleText": "产品加工"
- }
- }, {
- "path": "pages/traceability-product/machining/materialsList",
- "style": {
- "navigationBarTitleText": "生产原料"
- }
}
],
"subPackages": [{
@@ -248,6 +118,139 @@
"navigationBarTitleText": "农事记录",
"enablePullDownRefresh": false
}
+ },
+ {
+ "path": "mine/avatar/index",
+ "style": {
+ "navigationBarTitleText": "修改头像"
+ }
+ },
+ {
+ "path": "mine/info/index",
+ "style": {
+ "navigationBarTitleText": "个人信息"
+ }
+ },
+ {
+ "path": "mine/info/edit",
+ "style": {
+ "navigationBarTitleText": "编辑资料"
+ }
+ },
+ {
+ "path": "mine/pwd/index",
+ "style": {
+ "navigationBarTitleText": "修改密码"
+ }
+ },
+ {
+ "path": "mine/setting/index",
+ "style": {
+ "navigationBarTitleText": "应用设置"
+ }
+ },
+ {
+ "path": "mine/help/index",
+ "style": {
+ "navigationBarTitleText": "常见问题"
+ }
+ },
+ {
+ "path": "mine/about/index",
+ "style": {
+ "navigationBarTitleText": "关于我们"
+ }
+ }, {
+ "path": "mine/business/index",
+ "style": {
+ "navigationBarTitleText": "企业信息"
+ }
+ }, {
+ "path": "mine/base/index",
+ "style": {
+ "navigationBarTitleText": "基地信息"
+ }
+ }, {
+ "path": "mine/base/baseList",
+ "style": {
+ "navigationBarTitleText": "基地列表"
+ }
+ },
+ {
+ "path": "common/webview/index",
+ "style": {
+ "navigationBarTitleText": "浏览网页"
+ }
+ },
+ {
+ "path": "common/textview/index",
+ "style": {
+ "navigationBarTitleText": "浏览文本"
+ }
+ },
+ {
+ "path": "traceability-code/inventory",
+ "style": {
+ "navigationBarTitleText": "库存溯源码"
+ }
+ },
+ {
+ "path": "traceability-code/sales",
+ "style": {
+ "navigationBarTitleText": "销售溯源码"
+ }
+ },
+ {
+ "path": "traceability-product/index",
+ "style": {
+ "navigationBarTitleText": "溯源产品"
+ }
+ },
+ {
+ "path": "traceability-product/delivery/index",
+ "style": {
+ "navigationBarTitleText": "配送记录"
+ }
+ },
+ {
+ "path": "traceability-product/delivery/deliveryEdit",
+ "style": {
+ "navigationBarTitleText": "产品配送"
+ }
+ },
+ {
+ "path": "traceability-product/sales/index",
+ "style": {
+ "navigationBarTitleText": "销售记录"
+ }
+ },
+ {
+ "path": "traceability-product/sales/salesEdit",
+ "style": {
+ "navigationBarTitleText": "产品销售"
+ }
+ },
+ {
+ "path": "traceability-product/loss/index",
+ "style": {
+ "navigationBarTitleText": "报损记录"
+ }
+ },
+ {
+ "path": "traceability-product/loss/lossEdit",
+ "style": {
+ "navigationBarTitleText": "产品报损"
+ }
+ }, {
+ "path": "traceability-product/machining/index",
+ "style": {
+ "navigationBarTitleText": "产品加工"
+ }
+ }, {
+ "path": "traceability-product/machining/materialsList",
+ "style": {
+ "navigationBarTitleText": "生产原料"
+ }
}
]
}],
@@ -294,6 +297,7 @@
"globalStyle": {
"navigationBarTextStyle": "black",
"navigationBarTitleText": "RuoYi",
- "navigationBarBackgroundColor": "#FFFFFF"
+ "navigationBarBackgroundColor": "#FFFFFF",
+ "usingComponents": {}
}
}
\ No newline at end of file
diff --git a/pages/block/index.vue b/pages/block/index.vue
index a89f1e6..b62ce58 100644
--- a/pages/block/index.vue
+++ b/pages/block/index.vue
@@ -67,6 +67,12 @@ export default {
}
};
},
+ watch: {
+ "$store.state.user.baseId"(newValue, oldVal) {
+ this.baseId=newValue
+ this.$refs.paging.reload();
+ }
+ },
onLoad() {
this.dataList = [];
// setTimeout(()=>{
@@ -154,7 +160,7 @@ export default {
.then((res) => {
uni.showToast({
title: '删除成功',
- icon: 'none',
+ icon: 'success',
success() {
this_.queryList();
}
diff --git a/pages/index.vue b/pages/index.vue
index 99331e7..ec6d87a 100644
--- a/pages/index.vue
+++ b/pages/index.vue
@@ -55,7 +55,7 @@
-
+
@@ -65,7 +65,7 @@
-
+
@@ -75,7 +75,7 @@
-
+
@@ -85,7 +85,7 @@
-
+
@@ -99,7 +99,7 @@
-
+
溯源产品
@@ -111,7 +111,7 @@
-
+
销售溯源码
@@ -121,7 +121,7 @@
-
+
库存溯源码
diff --git a/pages/login.vue b/pages/login.vue
index d93e988..a7fd5d2 100644
--- a/pages/login.vue
+++ b/pages/login.vue
@@ -14,7 +14,7 @@
-
@@ -30,22 +30,22 @@
\ No newline at end of file
+
diff --git a/pages/traceability-product/loss/index.vue b/sunPages/traceability-product/loss/index.vue
similarity index 100%
rename from pages/traceability-product/loss/index.vue
rename to sunPages/traceability-product/loss/index.vue
diff --git a/pages/traceability-product/loss/lossEdit.vue b/sunPages/traceability-product/loss/lossEdit.vue
similarity index 94%
rename from pages/traceability-product/loss/lossEdit.vue
rename to sunPages/traceability-product/loss/lossEdit.vue
index 2a854c9..01cc41d 100644
--- a/pages/traceability-product/loss/lossEdit.vue
+++ b/sunPages/traceability-product/loss/lossEdit.vue
@@ -115,10 +115,11 @@
icon: 'success',
duration: 2000,
complete: function() {
- setTimeout(function() {
- uni.redirectTo({
- url: '/pages/traceability-product/index'
- });
+ uni.setStorageSync( 'canRefresh', 'true');
+ setTimeout(function() {
+ uni.navigateBack({
+ delta: 1
+ })
}, 2000);
}
})
@@ -139,7 +140,7 @@
// 选择报损类型
LossTypeChange(e) {
- this.CurrenLossType = e.detail.value
+ this.CurrenLossType = e.detail.value
},
// 格式化小数两位
@@ -155,4 +156,4 @@
\ No newline at end of file
+
diff --git a/pages/traceability-product/machining/index.vue b/sunPages/traceability-product/machining/index.vue
similarity index 99%
rename from pages/traceability-product/machining/index.vue
rename to sunPages/traceability-product/machining/index.vue
index cf875da..7d54533 100644
--- a/pages/traceability-product/machining/index.vue
+++ b/sunPages/traceability-product/machining/index.vue
@@ -307,7 +307,7 @@
complete: function() {
setTimeout(function() {
uni.redirectTo({
- url: '/pages/traceability-product/machining/index'
+ url: '/sunPages/traceability-product/machining/index'
});
}, 2000);
}
@@ -428,7 +428,7 @@
goMaterials() {
const data = encodeURIComponent(JSON.stringify(this.formData));
uni.redirectTo({
- url: '/pages/traceability-product/machining/materialsList?params=' + data
+ url: '/sunPages/traceability-product/machining/materialsList?params=' + data
});
},
/** 获取库存 */
diff --git a/pages/traceability-product/machining/materialsList.vue b/sunPages/traceability-product/machining/materialsList.vue
similarity index 98%
rename from pages/traceability-product/machining/materialsList.vue
rename to sunPages/traceability-product/machining/materialsList.vue
index bbf44bb..add8bf2 100644
--- a/pages/traceability-product/machining/materialsList.vue
+++ b/sunPages/traceability-product/machining/materialsList.vue
@@ -130,7 +130,7 @@
})
const data = encodeURIComponent(JSON.stringify(this.reviceData));
uni.redirectTo({
- url: '/pages/traceability-product/machining/index?params=' + data
+ url: '/sunPages/traceability-product/machining/index?params=' + data
});
},
@@ -155,4 +155,4 @@
\ No newline at end of file
+
diff --git a/pages/traceability-product/sales/index.vue b/sunPages/traceability-product/sales/index.vue
similarity index 100%
rename from pages/traceability-product/sales/index.vue
rename to sunPages/traceability-product/sales/index.vue
diff --git a/pages/traceability-product/sales/salesEdit.vue b/sunPages/traceability-product/sales/salesEdit.vue
similarity index 96%
rename from pages/traceability-product/sales/salesEdit.vue
rename to sunPages/traceability-product/sales/salesEdit.vue
index 7f2e403..051bd3c 100644
--- a/pages/traceability-product/sales/salesEdit.vue
+++ b/sunPages/traceability-product/sales/salesEdit.vue
@@ -159,7 +159,7 @@
/** 提交按钮 */
async submitForm() {
- // 校验主表
+ // 校验主表
try {
this.formData.salesType = this.SalesTypeList[this.CurrenSalesType].value
await this.$refs['formRef'].validate()
@@ -170,11 +170,12 @@
icon: 'success',
duration: 2000,
complete: function() {
- setTimeout(function() {
- uni.redirectTo({
- url: '/pages/traceability-product/index'
- });
- }, 2000);
+ uni.setStorageSync( 'canRefresh', 'true');
+ setTimeout(function() {
+ uni.navigateBack({
+ delta: 1
+ })
+ }, 2000);
}
})
} catch (err) {
@@ -195,7 +196,7 @@
},
// 选择客户
- ClientChange(e) {
+ ClientChange(e) {
this.CurrenClient = e.detail.value
console.log(this.CurrenClient)
this.formData.customId = this.ClientList[this.CurrenClient].id
@@ -240,4 +241,4 @@
\ No newline at end of file
+
diff --git a/utils/request.js b/utils/request.js
index e7008d9..2132b5f 100644
--- a/utils/request.js
+++ b/utils/request.js
@@ -12,8 +12,8 @@ const request = config => {
const isToken = (config.headers || {}).isToken === false
config.header = config.header || {}
if (getAccessToken() && !isToken) {
- // config.header['Authorization'] = 'Bearer ' + getAccessToken()
- config.header['Authorization'] = 'Bearer ' + 'd9be75cd7b904a789c6bf62c6fed9ac2'
+ config.header['Authorization'] = 'Bearer ' + getAccessToken()
+ // config.header['Authorization'] = 'Bearer ' + '888cfc9e0903437b87e44ef7064c7171'
}
// 设置租户 TODO 芋艿:强制 1 先
config.header['tenant-id'] = '1';